From b9d4026f85a38178529907eddebf4fe17a0c60b9 Mon Sep 17 00:00:00 2001 From: Thomas Haller Date: Fri, 11 Dec 2020 11:05:10 +0100 Subject: [PATCH] tools: improve detection of "ci-fairy" command in "tools/check-gitlab-ci.sh" The previous implementation would print ./tools/check-gitlab-ci.sh: line 22: ci-fairy: command not found also, it's not nice to execute the program, just to find out whether we have it. --- tools/check-gitlab-ci.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/check-gitlab-ci.sh b/tools/check-gitlab-ci.sh index 30e64a99f..8ad0fbb26 100755 --- a/tools/check-gitlab-ci.sh +++ b/tools/check-gitlab-ci.sh @@ -23,7 +23,7 @@ if ! [ -f ./.gitlab-ci.yml ] ; then exit 0 fi -if ! ci-fairy --help 2>&1 >/dev/null ; then +if ! command -v ci-fairy &> /dev/null ; then # ci-fairy not available. Cannot check. exit 0 fi