From 85cc81a5fb7a7faa7eb40a141d9ed7e840b3f24a Mon Sep 17 00:00:00 2001 From: Kartik Agaram Date: Wed, 3 Jul 2019 23:39:51 -0700 Subject: . Revert a bad merge. --- subx/run_one_test.sh | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/subx/run_one_test.sh b/subx/run_one_test.sh index 7ac3e5d0..caecd63c 100755 --- a/subx/run_one_test.sh +++ b/subx/run_one_test.sh @@ -4,9 +4,10 @@ if [[ $2 == 'test-'* ]] then - export TEST_NAME=$2 - echo $TEST_NAME > /tmp/last_test_run -elif [[ -e /tmp/last_test_run ]] + TEST_NAME=$2 envsubst '$TEST_NAME' < run_one_test.subx > /tmp/run_one_test.subx + FILES=$(ls [0-9]*.subx apps/subx-common.subx $1 |sort |uniq) + echo $FILES > /tmp/last_run_files +elif [[ -e /tmp/last_run_files ]] then FILES=`cat /tmp/last_run_files` else @@ -15,12 +16,7 @@ else fi set -e -if [[ $1 == */* ]] -then - CFLAGS=$CFLAGS ./subx --debug translate [0-9]*.subx apps/subx-common.subx $1 /tmp/run_one_test.subx -o /tmp/a.elf -else - # don't mention files twice - CFLAGS=$CFLAGS ./subx --debug translate [0-9]*.subx apps/subx-common.subx /tmp/run_one_test.subx -o /tmp/a.elf -fi + # turn newlines into spaces +CFLAGS=$CFLAGS ./subx --debug translate $(echo $FILES) /tmp/run_one_test.subx -o /tmp/a.elf ./subx --debug --trace run /tmp/a.elf -- cgit 1.4.1-2-gfad0