summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurent Alfonsi <laurent.alfonsi@linaro.org>2022-12-22 13:38:52 +0100
committerLaurent Alfonsi <laurent.alfonsi@linaro.org>2022-12-22 13:41:45 +0100
commit13172efee772c49755239b4259f6432d29751a49 (patch)
tree1d5e6842f7f88e7683ceb4f2bb88c6cf1114435c
parent6db9efff1c18ba6887e559cdee906c772a69a319 (diff)
tcwg-report-ci-status.sh: Fixup after jenkins upgrade
Change-Id: If9a27154026774195a83c2e6ea17bf33dd33c897
-rwxr-xr-xtcwg-report-ci-status.sh49
1 files changed, 27 insertions, 22 deletions
diff --git a/tcwg-report-ci-status.sh b/tcwg-report-ci-status.sh
index 45142539..b85fb4bb 100755
--- a/tcwg-report-ci-status.sh
+++ b/tcwg-report-ci-status.sh
@@ -12,37 +12,42 @@ for view in "${views[@]}"; do
done
# Print INSTANT PICTURE status
-printf "%-20s | %13s | %13s | %13s |\n" \
- "TODAY PICTURE" "Success" "In progress" "Failed"
-printf "========================================================================\n"
+list_pat=("Success" "In progress" "Failed" "Aborted" "Disabled")
+printf "%-22s | %13s | %13s | %13s | %13s | %13s |\n" "TODAY PICTURE" "${list_pat[@]}"
+printf "========================================================================================================\n"
for view in "${views[@]}"; do
- for pat in "Success" "In progress" "Failed"; do
- nb[$pat]=$(grep -c "tooltip=\"$pat\"" < "/tmp/$view.html")
- all[$pat]=$((all[$pat] + nb[$pat]))
+ printf "%-22s |" "$view"
+ for pat in "${list_pat[@]}"; do
+ nb["$pat"]=$(grep -c "tooltip=\"$pat\"" < "/tmp/$view.html")
+ all["$pat"]=$((all["$pat"] + nb["$pat"]))
+ printf " %13s |" "${nb["$pat"]}"
done
- printf "%-20s | %13s | %13s | %13s |\n" \
- "$view" "${nb[Success]}" "${nb[In progress]}" "${nb[Failed]}"
+ printf "\n"
done
-printf "========================================================================\n"
-printf "%-20s | %13s | %13s | %13s |\n" \
- "TOTAL" "${all[Success]}" "${all[In progress]}" "${all[Failed]}"
+printf "========================================================================================================\n"
+printf "%-22s | %13s | %13s | %13s | %13s | %13s |\n" \
+ "TOTAL" "${all[Success]}" "${all[In progress]}" "${all[Failed]}" "${all[Aborted]}" "${all[Disabled]}"
echo ""
echo ""
# Print WHEATHER PICTURE status
-printf "%-20s | %13s | %13s | %13s | %13s | %13s |\n" \
- "WHEATHER PICTURE" "sunny" "partly-cloudy" "cloudy" "rainy" "pouring"
-printf "========================================================================================================\n"
+list_name=("No-fail" "1-fail" "2-fails" "3-fails" "4-fails" "All-fails")
+list_pat=("No recent" "1 out of the last 5" "2 out of the last 5" "3 out of the last 5" "4 out of the last 5" "All recent")
+
+printf "%-22s | %13s | %13s | %13s | %13s | %13s | %13s |\n" "WHEATHER (5 last runs)" "${list_name[@]}"
+printf "========================================================================================================================\n"
for view in "${views[@]}"; do
- for pat in "sunny" "partly-cloudy" "cloudy" "rainy" "pouring"; do
- nb[$pat]=$(grep -c "#weather-$pat\"" < "/tmp/$view.html")
- all[$pat]=$((all[$pat] + nb[$pat]))
+ printf "%-22s |" "$view"
+ for nbfail in {0..5}; do
+ pat="${list_pat[$nbfail]}"
+ nb["$nbfail"]=$(grep -c "Build stability: $pat builds failed." < "/tmp/$view.html")
+ all["$nbfail"]=$((all["$nbfail"] + nb["$nbfail"]))
+ printf " %13s |" "${nb[$nbfail]}"
done
- printf "%-20s | %13s | %13s | %13s | %13s | %13s |\n" \
- "$view" "${nb[sunny]}" "${nb[partly-cloudy]}" "${nb[cloudy]}" "${nb[rainy]}" "${nb[pouring]}"
+ printf "\n"
done
-printf "========================================================================================================\n"
-printf "%-20s | %13s | %13s | %13s | %13s | %13s |\n" \
- "TOTAL" "${all[sunny]}" "${all[partly-cloudy]}" "${all[cloudy]}" "${all[rainy]}" "${all[pouring]}"
+printf "========================================================================================================================\n"
+printf "%-22s | %13s | %13s | %13s | %13s | %13s | %13s |\n" \
+ "TOTAL" "${all[0]}" "${all[1]}" "${all[2]}" "${all[3]}" "${all[4]}" "${all[5]}"