From 4bd0de444b5ce883a3a9b56bf3449ecff22396ae Mon Sep 17 00:00:00 2001 From: midipix Date: Sun, 20 Oct 2019 15:46:04 +0000 Subject: build system: employ the cd -- idiom for good measure. --- sofort/tools/version.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sofort') diff --git a/sofort/tools/version.sh b/sofort/tools/version.sh index caf5c5f..61fa364 100755 --- a/sofort/tools/version.sh +++ b/sofort/tools/version.sh @@ -51,7 +51,7 @@ if [ -z "$srcdir" ] || [ -z "$output" ] || [ -z "$prefix" ]; then usage fi -cd "$srcdir" +cd -- "$srcdir" gitver=$(git rev-parse --verify HEAD 2>/dev/null) || gitver="unknown" cvdate=$(git show -s --format=%ci $gitver 2>/dev/null) || cvdate=$(date) @@ -59,7 +59,7 @@ cvdate=$(git show -s --format=%ci $gitver 2>/dev/null) || cvdate=$(date) vmacro=$(printf '%s' "$prefix"'_GIT_VERSION' | tr '[:lower:]' '[:upper:]') dmacro=$(printf '%s' "$prefix"'_GIT_DATE ' | tr '[:lower:]' '[:upper:]') -cd "$workdir" +cd -- "$workdir" # three -- cgit v1.2.3