From 95ad6c33c7744da263c6cf05840cbfdfd790bb89 Mon Sep 17 00:00:00 2001 From: Pietro Albini Date: Tue, 29 Oct 2019 10:32:51 +0100 Subject: Apply suggestions from lzutao Co-Authored-By: lzutao --- src/ci/scripts/should-skip-this.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/ci/scripts') diff --git a/src/ci/scripts/should-skip-this.sh b/src/ci/scripts/should-skip-this.sh index a38099a2db7..f945db0ada2 100755 --- a/src/ci/scripts/should-skip-this.sh +++ b/src/ci/scripts/should-skip-this.sh @@ -10,7 +10,7 @@ source "$(cd "$(dirname "$0")" && pwd)/../shared.sh" if [[ -z "${CI_ONLY_WHEN_SUBMODULES_CHANGED+x}" ]]; then echo "Executing the job since there is no skip rule in effect" -elif git diff HEAD^ | grep "^index .* 160000" >/dev/null 2>&1; then +elif git diff HEAD^ | grep --quiet "^index .* 160000"; then # Submodules pseudo-files inside git have the 160000 permissions, so when # those files are present in the diff a submodule was updated. echo "Executing the job since submodules are updated" -- cgit 1.4.1-3-g733a5