summaryrefslogtreecommitdiff
path: root/git-submodule.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2009-06-20 21:51:13 -0700
committerJunio C Hamano <gitster@pobox.com>2009-06-20 21:51:13 -0700
commita49eb197d809d2d7efbd81d935c61e1a0caa983e (patch)
tree06512c227fba59faaee57dcfe1ba71f049c4d0a7 /git-submodule.sh
parentc28a17f270a51a4ed5e432e83c0ed962361a37c9 (diff)
parent42b491786260eb17d97ea9fb1c4b70075bca9523 (diff)
downloadgit-a49eb197d809d2d7efbd81d935c61e1a0caa983e.tar.gz
Merge branch 'ph/submodule-rebase'
* ph/submodule-rebase: git-submodule: add support for --merge. Conflicts: Documentation/git-submodule.txt git-submodule.sh
Diffstat (limited to 'git-submodule.sh')
-rwxr-xr-xgit-submodule.sh11
1 files changed, 10 insertions, 1 deletions
diff --git a/git-submodule.sh b/git-submodule.sh
index 19a3a840fd..f4f3562671 100755
--- a/git-submodule.sh
+++ b/git-submodule.sh
@@ -5,7 +5,7 @@
# Copyright (c) 2007 Lars Hjemli
USAGE="[--quiet] [--cached] \
-[add [-b branch] <repo> <path>]|[status|init|update [-i|--init] [-N|--no-fetch]|summary [-n|--summary-limit <n>] [<commit>]] \
+[add [-b branch] <repo> <path>]|[status|init|update [-i|--init] [-N|--no-fetch] [--rebase|--merge]|summary [-n|--summary-limit <n>] [<commit>]] \
[--] [<path>...]|[foreach <command>]|[sync [--] [<path>...]]"
OPTIONS_SPEC=
. git-sh-setup
@@ -356,6 +356,10 @@ cmd_update()
reference="$1"
shift
;;
+ -m|--merge)
+ shift
+ update="merge"
+ ;;
--)
shift
break
@@ -426,6 +430,11 @@ cmd_update()
action="rebase"
msg="rebased onto"
;;
+ merge)
+ command="git merge"
+ action="merge"
+ msg="merged in"
+ ;;
*)
command="git checkout $force -q"
action="checkout"