From 72ecd841df155135f283e7107d26723ffa80a65e Mon Sep 17 00:00:00 2001 From: Gerhard Hoffmann Date: Thu, 25 May 2023 17:03:11 +0200 Subject: [PATCH] test for syntax errors --- .githooks/post-checkout | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.githooks/post-checkout b/.githooks/post-checkout index 5584931..e7daf2f 100755 --- a/.githooks/post-checkout +++ b/.githooks/post-checkout @@ -30,7 +30,7 @@ if [ -f $CHECKOUT_HISTORY_FILE ]; then readarray opkg_commands < <(cat $OPKG_COMMANDS_FILE) for opkg_c in "${opkg_commands[@]}"; do # check for empty lines - if [[ -n $opkg_c ]]; then + if [ "$opkg_c" ]; then echo "CC=$opkg_c" # check if line is not starting with '#' if ! grep -qE "^\s*[#]+.*$" <<< "$opkg_c"; then