From 68061b61ae2e8c61c46f0366ef9db8142577390b Mon Sep 17 00:00:00 2001 From: bol-van Date: Tue, 30 Jul 2024 17:37:28 +0300 Subject: [PATCH] blockcheck: tolerate absense of config and config.default --- blockcheck.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blockcheck.sh b/blockcheck.sh index 637caff..927e6a6 100755 --- a/blockcheck.sh +++ b/blockcheck.sh @@ -5,7 +5,7 @@ EXEDIR="$(cd "$EXEDIR"; pwd)" ZAPRET_CONFIG="$EXEDIR/config" ZAPRET_BASE="$EXEDIR" -[ -f "$ZAPRET_CONFIG" ] || cp "${ZAPRET_CONFIG}.default" "$ZAPRET_CONFIG" +[ -f "$ZAPRET_CONFIG" ] || [ -f "${ZAPRET_CONFIG}.default" ] && cp "${ZAPRET_CONFIG}.default" "$ZAPRET_CONFIG" [ -f "$ZAPRET_CONFIG" ] && . "$ZAPRET_CONFIG" . "$ZAPRET_BASE/common/base.sh" . "$ZAPRET_BASE/common/dialog.sh"