rlb pushed a commit to branch main
in repository guile.

commit 6495b4d578116aeadf9f4156364431609f42275f
Author: Rob Browning <r...@defaultvalue.org>
AuthorDate: Fri Aug 25 17:14:41 2023 -0500

    check-guile.in: improve quoting (e.g. paths with spaces)
    
    * check-guile.in: improve shell quoting.
---
 check-guile.in | 23 +++++++++--------------
 1 file changed, 9 insertions(+), 14 deletions(-)

diff --git a/check-guile.in b/check-guile.in
index 773e5da14..68f353c6e 100644
--- a/check-guile.in
+++ b/check-guile.in
@@ -15,25 +15,22 @@ set -e
 top_builddir=@top_builddir_absolute@
 top_srcdir=@top_srcdir_absolute@
 
-TEST_SUITE_DIR=${top_srcdir}/test-suite
-export TEST_SUITE_DIR
+export TEST_SUITE_DIR="${top_srcdir}/test-suite"
 
 if [ x"$1" = x-i ] ; then
-    guile=$2
-    shift
-    shift
+    guile="$2"
+    shift 2
 else
-    guile=${top_builddir}/meta/guile
+    guile="${top_builddir}/meta/guile"
 fi
 
-GUILE_LOAD_PATH=$TEST_SUITE_DIR
-export GUILE_LOAD_PATH
+export GUILE_LOAD_PATH="$TEST_SUITE_DIR"
 
 if [ -f "$guile" -a -x "$guile" ] ; then
-    echo Testing $guile ... "$@"
-    echo with GUILE_LOAD_PATH=$GUILE_LOAD_PATH
+    echo "Testing $guile ..." "$@"
+    echo "with GUILE_LOAD_PATH=$GUILE_LOAD_PATH"
 else
-    echo ERROR: Cannot execute $guile
+    echo "ERROR: Cannot execute $guile"
     exit 1
 fi
 
@@ -42,11 +39,9 @@ if [ ! -f guile-procedures.txt ] ; then
    @LN_S@ libguile/guile-procedures.txt .
 fi
 
-exec $guile \
+exec "$guile" \
     --debug \
     -L "$TEST_SUITE_DIR" \
     --no-auto-compile -e main -s "$TEST_SUITE_DIR/guile-test" \
     --test-suite "$TEST_SUITE_DIR/tests" \
     --log-file check-guile.log "$@"
-
-# check-guile ends here

Reply via email to