@@ -243,8 +243,16 @@ main () {
test -n "$allow_addmerge" || die_incompatible_opt "$opt" "$arg_command"
arg_addmerge_squash=
;;
- -S*|--gpg-sign=*|--no-gpg-sign)
+ -S|--gpg-sign|--no-gpg-sign)
arg_gpgsign="${opt}"
+ case $1 in
+ -*)
+ ;;
+ *)
+ arg_gpgsign=${opt}${1}
+ shift
+ ;;
+ esac
;;
--)
break
@@ -1053,10 +1061,10 @@ cmd_merge () {
if test -n "$arg_addmerge_message"
then
- git merge --no-ff -Xsubtree="$arg_prefix" \
+ git merge --no-ff $arg_gpgsign -Xsubtree="$arg_prefix" \
--message="$arg_addmerge_message" "$rev"
else
- git merge --no-ff -Xsubtree="$arg_prefix" $rev
+ git merge --no-ff $arg_gpgsign -Xsubtree="$arg_prefix" $rev
fi
}
@@ -47,7 +47,7 @@ last_commit_subject () {
# pre-2.32.0 versions of 'git subtree' would write the hash of the tag
# (sub1 below), instead of the commit (sub1^{commit}) in the
# "git-subtree-split" trailer.
-# We immitate this behaviour below using a replace ref.
+# We imitate this behaviour below using a replace ref.
# This function creates 3 repositories:
# - $1
# - $1-sub (added as subtree "sub" in $1)