Commit ebaa1bdf6772cd666a96cb7d2bc8c3a396a754f1

Thomas de Grivel 2023-02-15T22:19:41

wip

diff --git a/bin/ansi2html b/bin/ansi2html
index 0a31ea8..835a188 100755
--- a/bin/ansi2html
+++ b/bin/ansi2html
@@ -2,9 +2,9 @@
 set -e
 
 ansi2html_sed () {
-    sed -e 's|<|&lt;|g' \
-        -e 's|>|&gt;|g' \
-        -e 's|&|&amp;|g' \
+    sed -e 's|&|\&amp;|g' \
+        -e 's|<|\&lt;|g' \
+        -e 's|>|\&gt;|g' \
         -e "s|$(printf '\33\\[0;34m')|<span style=\"color: blue;\">|g" \
         -e "s|$(printf '\33\\[0;35m')|<span style=\"color: purple;\">|g" \
         -e "s|$(printf '\33\\[0m')|</span>|g"
diff --git a/bin/shpkg_ci b/bin/shpkg_ci
index 46a4262..2ef45ce 100755
--- a/bin/shpkg_ci
+++ b/bin/shpkg_ci
@@ -74,12 +74,12 @@ EOF
 }
 
 logs2html () {
-    for F in "${SHPKG_CI_LOG_DIR}"/"${SHPKG_REPO}".*.log; do
+    for F in "${SHPKG_CI_LOG_DIR}"/*.log; do
         STATUS_FILE="$(log_status_file "$F")"
-        if ! [ -f "$F.html" ] ||
-                [ "$F" -nt "$F.html" ] ||
-                [ "${STATUS_FILE}" -nt "$F.html" ] ||
-                [ "$0" -nt "$F.html" ]; then
+        if [ ! -f "$F.html" ] ||
+               [ "$F" -nt "$F.html" ] ||
+               [ "${STATUS_FILE}" -nt "$F.html" ] ||
+               [ "$0" -nt "$F.html" ]; then
             verbose 2 log2html "$F"
         fi
     done