Skip to content

Commit 505857c

Browse files
committed
squash! git am: ignore dirty submodules
Drop this patch because it prevents `git rebase --continue` after resolving a submodule-only commit's conflict during a rebase. This reverts commit fbe1f04.
1 parent 00fb16b commit 505857c

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

git-am.sh

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -606,8 +606,7 @@ case "$resolved" in
606606
'')
607607
files=$(git ls-files) ;;
608608
?*)
609-
files=$(git diff-index --ignore-submodules --cached \
610-
--name-only HEAD --) ;;
609+
files=$(git diff-index --cached --name-only HEAD --) ;;
611610
esac || exit
612611
if test "$files"
613612
then
@@ -787,8 +786,7 @@ To restore the original branch and stop patching run \"\$cmdline --abort\"."
787786
case "$resolved$interactive" in
788787
tt)
789788
# This is used only for interactive view option.
790-
git diff-index --ignore-submodules -p --cached \
791-
HEAD -- >"$dotest/patch"
789+
git diff-index -p --cached HEAD -- >"$dotest/patch"
792790
;;
793791
esac
794792
esac
@@ -864,7 +862,7 @@ To restore the original branch and stop patching run \"\$cmdline --abort\"."
864862
# trust what the user has in the index file and the
865863
# working tree.
866864
resolved=
867-
git diff-index --ignore-submodules --quiet --cached HEAD -- && {
865+
git diff-index --quiet --cached HEAD -- && {
868866
gettextln "No changes - did you forget to use 'git add'?
869867
If there is nothing left to stage, chances are that something else
870868
already introduced the same changes; you might want to skip this patch."
@@ -888,8 +886,7 @@ did you forget to use 'git add'?"
888886
then
889887
# Applying the patch to an earlier tree and merging the
890888
# result may have produced the same tree as ours.
891-
git diff-index --ignore-submodules --quiet --cached \
892-
HEAD -- && {
889+
git diff-index --quiet --cached HEAD -- && {
893890
say "$(gettext "No changes -- Patch already applied.")"
894891
go_next
895892
continue

0 commit comments

Comments
 (0)