From e92047154e790e33a4e52c1d74fecb73db84270e Mon Sep 17 00:00:00 2001 From: tituspijean Date: Wed, 29 Sep 2021 00:11:05 +0200 Subject: [PATCH] Add check on number of processed assets in updater.sh --- .github/workflows/updater.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.github/workflows/updater.sh b/.github/workflows/updater.sh index 9604311..f2120d1 100644 --- a/.github/workflows/updater.sh +++ b/.github/workflows/updater.sh @@ -53,6 +53,8 @@ echo "${#assets[@]} available asset(s)" # Here we use the $assets variable to get the resources published in the upstream release. +count=0 + # Let's loop over the array of assets URLs for asset_url in ${assets[@]}; do @@ -102,12 +104,19 @@ SOURCE_FILENAME= EOT echo "... conf/$src.src updated" +count=$((count+1)) + else echo "... asset ignored" fi done +if [ $count == 0 ]; then + echo "::warning ::None of the assets were processed." + exit 0 +fi + #================================================= # SPECIFIC UPDATE STEPS #=================================================