From 5cc370ceb60b8571de636b30e731e2aad97b3958 Mon Sep 17 00:00:00 2001 From: Syndamia Date: Sun, 14 Apr 2024 10:25:44 +0300 Subject: [p3] Fixed logic for disabling timestamp.txt --- csg | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/csg b/csg index a548c9e..5c96dff 100755 --- a/csg +++ b/csg @@ -26,7 +26,7 @@ Arguments: Variables (you can predefine): CSG_TIMESTAMP_FILE File path for git-based timestamps (when git exists) Default: "./timestamps.txt" - Disable: "" + Disable: "none" CSG_TMP_DIR Directory to put temporary files Default: "/tmp" CSG_AWK awk executable and flags @@ -73,6 +73,7 @@ AWKSCRIPTS="$5" ### "Global" variables : ${CSG_TIMESTAMP_FILE:="$(realpath ./timestamps.txt)"} +[ "$CSG_TIMESTAMP_FILE" = 'none' ] && CSG_TIMESTAMP_FILE="" : ${CSG_TMP_DIR:='/tmp'} [ ! -d "$CSG_TMP_DIR" ] && echo "[Error] $CSG_TMP_DIR (\$CSG_TMP_DIR) doesn't exist!" \ -- cgit v1.3.1-23-gd82d