From 98a69bc7799af4c0e29a43bd808cf64cb66a0b16 Mon Sep 17 00:00:00 2001 From: Gerhard Hoffmann Date: Mon, 5 Jun 2023 15:58:27 +0200 Subject: [PATCH] check for existence of opkg_commands-file (2) --- .githooks/post-checkout | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.githooks/post-checkout b/.githooks/post-checkout index 7414cab..76812cf 100755 --- a/.githooks/post-checkout +++ b/.githooks/post-checkout @@ -26,8 +26,8 @@ write_log_file () { echo "DOWNLOAD, /etc/psa_config/DC2C_print04.json, $now, N/A" >> $GIT_UPDATE_LOG echo "DOWNLOAD, /etc/psa_config/DC2C_print29.json, $now, N/A" >> $GIT_UPDATE_LOG echo "DOWNLOAD, /etc/psa_config/DC2C_print32.json, $now, N/A" >> $GIT_UPDATE_LOG - if grep -qE . "${OPKG_COMMANDS_FILE}"; then - if [ -f "$OPKG_COMMANDS_FILE" ]; then + if [ -f "$OPKG_COMMANDS_FILE" ]; then + if grep -qE . "${OPKG_COMMANDS_FILE}"; then readarray opkg_commands < <(cat $OPKG_COMMANDS_FILE) for opkg_c in "${opkg_commands[@]}"; do # check for lines longer than 'opkg '