Display summary of warnings (#932)

This commit is contained in:
Zach Borboa
2025-03-08 13:44:18 -05:00
committed by GitHub
parent 8d83782c06
commit 41cc699798
5 changed files with 16 additions and 0 deletions
+11
View File
@@ -0,0 +1,11 @@
warning_count="${#warnings[@]}"
if [[ "${warning_count}" -ge 1 ]]; then
echo -e "\nWarnings found: ${warning_count}"
iter=0
for value in "${warnings[@]}"; do
((iter++))
echo -e "\nWarning ${iter} of ${warning_count}:"
echo "⚠️ ${value}" | perl -pe 's/^(.*)$/\t\1/'
done
fi
+2
View File
@@ -2,6 +2,7 @@
set -x
warnings=()
errors=()
if [[ "${CI}" == "true" ]]; then
@@ -55,6 +56,7 @@ source "run_static_analysis_check_psalm.sh"
set +x
source "display_warnings.inc.sh"
source "display_errors.inc.sh"
if [[ "${CI_PHP_FUTURE_RELEASE}" != "true" ]]; then
+1
View File
@@ -132,6 +132,7 @@ if [[ $(echo "${CI_PHP_VERSION} < 8.4" | bc -l) -eq 1 ]]; then
fi
else
echo "⚠️ Skipped running PHP-CS-Fixer coding standards check"
warnings+=("Skipped running PHP-CS-Fixer coding standards check")
fi
popd
@@ -27,6 +27,7 @@ if [[ $(echo "${CI_PHP_VERSION} >= 7.4" | bc -l) -eq 1 ]]; then
fi
else
echo "⚠️ Skipped running phpstan check"
warnings+=("Skipped running phpstan check")
fi
popd
+1
View File
@@ -12,6 +12,7 @@ set -x
if [[ ! -f "vendor/bin/psalm" ]]; then
echo "⚠️ Skipped running psalm static analysis check"
warnings+=("Skipped running psalm static analysis check")
else
vendor/bin/psalm --version