summaryrefslogtreecommitdiff
path: root/Documentation/gitmodules.txt
diff options
context:
space:
mode:
authorJohan Herland <johan@herland.net>2009-06-02 22:59:12 (GMT)
committerJunio C Hamano <gitster@pobox.com>2009-06-03 07:09:16 (GMT)
commit42b491786260eb17d97ea9fb1c4b70075bca9523 (patch)
tree3c330360a9fdc6abf984c5497ae3c9668009cf10 /Documentation/gitmodules.txt
parent329484256e0fe42676e93669122e7a5a007ef4ed (diff)
downloadgit-42b491786260eb17d97ea9fb1c4b70075bca9523.zip
git-42b491786260eb17d97ea9fb1c4b70075bca9523.tar.gz
git-42b491786260eb17d97ea9fb1c4b70075bca9523.tar.bz2
git-submodule: add support for --merge.
'git submodule update --merge' merges the commit referenced by the superproject into your local branch, instead of checking it out on a detached HEAD. As evidenced by the addition of "git submodule update --rebase", it is useful to provide alternatives to the default 'checkout' behaviour of "git submodule update". One such alternative is, when updating a submodule to a new commit, to merge that commit into the current local branch in that submodule. This is useful in workflows where you want to update your submodule from its upstream, but you cannot use --rebase, because you have downstream people working on top of your submodule branch, and you don't want to disrupt their work. Signed-off-by: Johan Herland <johan@herland.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/gitmodules.txt')
-rw-r--r--Documentation/gitmodules.txt6
1 files changed, 4 insertions, 2 deletions
diff --git a/Documentation/gitmodules.txt b/Documentation/gitmodules.txt
index 1b67f0a..5daf750 100644
--- a/Documentation/gitmodules.txt
+++ b/Documentation/gitmodules.txt
@@ -35,9 +35,11 @@ submodule.<name>.update::
If 'checkout' (the default), the new commit specified in the
superproject will be checked out in the submodule on a detached HEAD.
If 'rebase', the current branch of the submodule will be rebased onto
- the commit specified in the superproject.
+ the commit specified in the superproject. If 'merge', the commit
+ specified in the superproject will be merged into the current branch
+ in the submodule.
This config option is overridden if 'git submodule update' is given
- the '--rebase' option.
+ the '--merge' or '--rebase' options.
EXAMPLES