Merge branch 'cp/submodule-custom-update'
authorJunio C Hamano <gitster@pobox.com>
Mon, 15 Jul 2013 17:28:44 +0000 (10:28 -0700)
committerJunio C Hamano <gitster@pobox.com>
Mon, 15 Jul 2013 17:28:44 +0000 (10:28 -0700)
In addition to the choice from "rebase, merge, or checkout-detach",
allow a custom command to be used in "submodule update" to update
the working tree of submodules.

* cp/submodule-custom-update:
submodule update: allow custom command to update submodule working tree

1  2 
Documentation/git-submodule.txt
index bfff09062d028dc038f0926042f651084c1395d6,2f18f7daf80139802e787b9dd22899776dd67ec9..134282700c7831ad0af1770475ed5767dd980f72
@@@ -159,7 -159,9 +159,9 @@@ update:
        This will make the submodules HEAD be detached unless `--rebase` or
        `--merge` is specified or the key `submodule.$name.update` is set to
        `rebase`, `merge` or `none`. `none` can be overridden by specifying
-       `--checkout`.
+       `--checkout`. Setting the key `submodule.$name.update` to `!command`
+       will cause `command` to be run. `command` can be any arbitrary shell
+       command that takes a single argument, namely the sha1 to update to.
  +
  If the submodule is not yet initialized, and you just want to use the
  setting as stored in .gitmodules, you can automatically initialize the
@@@ -262,7 -264,7 +264,7 @@@ OPTION
  --remote::
        This option is only valid for the update command.  Instead of using
        the superproject's recorded SHA-1 to update the submodule, use the
 -      status of the submodule's remote tracking branch.  The remote used
 +      status of the submodule's remote-tracking branch.  The remote used
        is branch's remote (`branch.<name>.remote`), defaulting to `origin`.
        The remote branch used defaults to `master`, but the branch name may
        be overridden by setting the `submodule.<name>.branch` option in