bash : archive & name : add success report for checks.

This commit is contained in:
Dmitry Voronin 2023-10-26 18:54:05 +03:00
parent dbf1e70960
commit fe09fa9139
2 changed files with 7 additions and 2 deletions

View file

@ -98,9 +98,11 @@ archive_check()
((count++))
done
# report if any failed.
# report result.
if [[ ${failed} -gt 0 ]]; then
echo -e "${color_bred}Items failed to validate: ${failed}.${color_default}"
else
echo -e "${color_green}All successful.${color_default}"
fi
}

View file

@ -117,6 +117,7 @@ name_hash_check()
files="[^.]*"
total=$(ls -p | grep -v / | wc -l)
fi
# process.
for file in $files; do
# process only files.
@ -141,9 +142,11 @@ name_hash_check()
fi
done
# report if any failed.
# report result.
if [[ ${failed} -gt 0 ]]; then
echo -e "${color_bred}Items failed to validate: ${failed}.${color_default}"
else
echo -e "${color_green}All successful.${color_default}"
fi
}