From 39574fde09129371631d6895e909687fe5e42398 Mon Sep 17 00:00:00 2001 From: David Landa Marban Date: Mon, 17 Aug 2026 11:12:06 +0200 Subject: [PATCH] Small fix for sh docs --- tests/scripts/docs_check_outputs.sh | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/tests/scripts/docs_check_outputs.sh b/tests/scripts/docs_check_outputs.sh index 735f7cd..28426f4 100644 --- a/tests/scripts/docs_check_outputs.sh +++ b/tests/scripts/docs_check_outputs.sh @@ -1,23 +1,25 @@ -files=( - "test_outputs/docs_image/VTK_tracerTransport/tracerTransport_120.vtk" - "test_outputs/docs_device/VTK_tracerTransport/tracerTransport_120.vtk" -) +files=" +test_outputs/docs_image/VTK_tracerTransport/tracerTransport_120.vtk +test_outputs/docs_device/VTK_tracerTransport/tracerTransport_120.vtk +" missing_file="test_outputs/missing_docs_files.txt" missing=0 rm -f "$missing_file" -for f in "${files[@]}"; do - if [[ ! -f "$f" ]]; then +for f in $files; do + if [ ! -f "$f" ]; then echo "$f" >> "$missing_file" - ((missing++)) + missing=$((missing + 1)) fi done -if (( missing == 0 )); then +if [ "$missing" -eq 0 ]; then echo "All figures and files exist." + return 0 else echo "$missing figure(s) or file(s) missing." echo "See $missing_file" + return 1 fi