X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=git-stash.sh;h=4938ade589f2f7d1c69bd53f7bc7bc1bd33f488c;hb=06f60e8edf1eb3a91e1af6f255bf46154168dd86;hp=c2b68205a2b69eb91b2403e11238093fc65c04ef;hpb=319a36a5c2da8dd07993caac43b7820bff3b0d37;p=git.git diff --git a/git-stash.sh b/git-stash.sh index c2b68205a..4938ade58 100755 --- a/git-stash.sh +++ b/git-stash.sh @@ -15,8 +15,8 @@ trap 'rm -f "$TMP-*"' 0 ref_stash=refs/stash no_changes () { - git diff-index --quiet --cached HEAD -- && - git diff-files --quiet + git diff-index --quiet --cached HEAD --ignore-submodules -- && + git diff-files --quiet --ignore-submodules } clear_stash () { @@ -130,7 +130,7 @@ show_stash () { } apply_stash () { - git diff-files --quiet || + git diff-files --quiet --ignore-submodules || die 'Cannot restore on top of a dirty state' unstash_index=