@@ -586,7 +586,8 @@ case "$resolved" in
586
586
' ' )
587
587
files=$( git ls-files) ;;
588
588
?* )
589
- files=$( git diff-index --cached --name-only HEAD --) ;;
589
+ files=$( git diff-index --ignore-submodules --cached \
590
+ --name-only HEAD --) ;;
590
591
esac || exit
591
592
if test " $files "
592
593
then
@@ -760,7 +761,8 @@ To restore the original branch and stop patching run \"\$cmdline --abort\"."
760
761
case " $resolved$interactive " in
761
762
tt)
762
763
# This is used only for interactive view option.
763
- git diff-index -p --cached HEAD -- > " $dotest /patch"
764
+ git diff-index --ignore-submodules -p --cached \
765
+ HEAD -- > " $dotest /patch"
764
766
;;
765
767
esac
766
768
esac
@@ -836,7 +838,7 @@ To restore the original branch and stop patching run \"\$cmdline --abort\"."
836
838
# trust what the user has in the index file and the
837
839
# working tree.
838
840
resolved=
839
- git diff-index --quiet --cached HEAD -- && {
841
+ git diff-index --ignore-submodules -- quiet --cached HEAD -- && {
840
842
gettextln " No changes - did you forget to use 'git add'?
841
843
If there is nothing left to stage, chances are that something else
842
844
already introduced the same changes; you might want to skip this patch."
@@ -860,7 +862,8 @@ did you forget to use 'git add'?"
860
862
then
861
863
# Applying the patch to an earlier tree and merging the
862
864
# result may have produced the same tree as ours.
863
- git diff-index --quiet --cached HEAD -- && {
865
+ git diff-index --ignore-submodules --quiet --cached \
866
+ HEAD -- && {
864
867
say " $( gettext " No changes -- Patch already applied." ) "
865
868
go_next
866
869
continue
0 commit comments