Skip to content

Commit 8833662

Browse files
boklmgitster
authored andcommitted
am: parse options in stuck-long mode
There is no functional change. The reason for this change is to be able to add a new option taking an optional argument. Signed-off-by: Nicolas Vigier <[email protected]> Signed-off-by: brian m. carlson <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 51ba8ce commit 8833662

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

git-am.sh

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
SUBDIRECTORY_OK=Yes
66
OPTIONS_KEEPDASHDASH=
7-
OPTIONS_STUCKLONG=
7+
OPTIONS_STUCKLONG=t
88
OPTIONS_SPEC="\
99
git am [options] [(<mbox>|<Maildir>)...]
1010
git am [options] (--continue | --skip | --abort)
@@ -414,14 +414,14 @@ it will be removed. Please do not use it anymore."
414414
abort=t ;;
415415
--rebasing)
416416
rebasing=t threeway=t ;;
417-
--resolvemsg)
418-
shift; resolvemsg=$1 ;;
419-
--whitespace|--directory|--exclude|--include)
420-
git_apply_opt="$git_apply_opt $(sq "$1=$2")"; shift ;;
421-
-C|-p)
422-
git_apply_opt="$git_apply_opt $(sq "$1$2")"; shift ;;
423-
--patch-format)
424-
shift ; patch_format="$1" ;;
417+
--resolvemsg=*)
418+
resolvemsg="${1#--resolvemsg=}" ;;
419+
--whitespace=*|--directory=*|--exclude=*|--include=*)
420+
git_apply_opt="$git_apply_opt $(sq "$1")" ;;
421+
-C*|-p*)
422+
git_apply_opt="$git_apply_opt $(sq "$1")" ;;
423+
--patch-format=*)
424+
patch_format="${1#--patch-format=}" ;;
425425
--reject|--ignore-whitespace|--ignore-space-change)
426426
git_apply_opt="$git_apply_opt $1" ;;
427427
--committer-date-is-author-date)

0 commit comments

Comments
 (0)