summaryrefslogtreecommitdiff
path: root/t/t7810-grep.sh
diff options
context:
space:
mode:
authorAnthony Sottile <asottile@umich.edu>2017-08-18 01:38:51 (GMT)
committerJunio C Hamano <gitster@pobox.com>2017-08-18 02:02:23 (GMT)
commite1f68c66d575e09f325f3eda9ced1b2f4ef4b4f0 (patch)
tree4b267159f350ad35be2a068509f4da11d04c799f /t/t7810-grep.sh
parent3d9c5b5c4461957fbbc0479e037990db04ebb740 (diff)
downloadgit-e1f68c66d575e09f325f3eda9ced1b2f4ef4b4f0.zip
git-e1f68c66d575e09f325f3eda9ced1b2f4ef4b4f0.tar.gz
git-e1f68c66d575e09f325f3eda9ced1b2f4ef4b4f0.tar.bz2
git-grep: correct exit code with --quiet and -L
The handling of `status_only` no longer interferes with the handling of `unmatch_name_only`. `--quiet` no longer affects the exit code when using `-L`/`--files-without-match`. Signed-off-by: Anthony Sottile <asottile@umich.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t7810-grep.sh')
-rwxr-xr-xt/t7810-grep.sh5
1 files changed, 5 insertions, 0 deletions
diff --git a/t/t7810-grep.sh b/t/t7810-grep.sh
index cee4209..7395038 100755
--- a/t/t7810-grep.sh
+++ b/t/t7810-grep.sh
@@ -370,6 +370,11 @@ test_expect_success 'grep -L -C' '
test_cmp expected actual
'
+test_expect_success 'grep --files-without-match --quiet' '
+ git grep --files-without-match --quiet nonexistent_string >actual &&
+ test_cmp /dev/null actual
+'
+
cat >expected <<EOF
file:foo mmap bar_mmap
EOF