summaryrefslogtreecommitdiff
path: root/runtests.SH
diff options
context:
space:
mode:
authorAndy Dougherty <doughera@lafayette.edu>2014-03-13 15:44:19 -0400
committerAndy Dougherty <doughera@lafayette.edu>2014-03-18 07:15:36 -0400
commitf1397316ff9824d76d2953cfd3cef2bef5be92ee (patch)
tree619d21f8ca241253454bb0ec1861bcc6c010d082 /runtests.SH
parent32dfa2a7022d23efefa78556ec78725b0d2d4373 (diff)
downloadperl-f1397316ff9824d76d2953cfd3cef2bef5be92ee.tar.gz
Split file into parts with and without substitutions.
At this point, there are no functional changes. This just prepares the way for future work.
Diffstat (limited to 'runtests.SH')
-rwxr-xr-xruntests.SH17
1 files changed, 13 insertions, 4 deletions
diff --git a/runtests.SH b/runtests.SH
index 304b7195e8..481a237f6b 100755
--- a/runtests.SH
+++ b/runtests.SH
@@ -16,21 +16,26 @@ case "$0" in
esac
echo "Extracting runtests (with variable substitutions)"
rm -f runtests
+
$spitshell >runtests <<!GROK!THIS!
$startsh -e
# runtests.SH
#
+!GROK!THIS!
-export PATH || (echo "OOPS, this isn't sh. Desperation time. I will feed myself to sh."; sh \$0; kill \$\$)
+## In the following, dollars and backticks do not need the extra backslash.
+$spitshell >>runtests <<'!NO!SUBS!'
-case \$# in
+export PATH || (echo "OOPS, this isn't sh. Desperation time. I will feed myself to sh."; sh $0; kill $$)
+
+case $# in
0)
echo "runtests tty_flag ..."
exit 1
;;
esac
-case \$1 in
+case $1 in
tty)
tty=Y
;;
@@ -50,12 +55,16 @@ case \$1 in
;;
esac
-if test X"\$TESTFILE" = X; then
+if test X"$TESTFILE" = X; then
TESTFILE=TEST
fi
cd t
+!NO!SUBS!
+
+## In the following, dollars and backticks do need the extra backslash.
+$spitshell >>runtests <<!GROK!THIS!
# The second branch is for testing without a tty or controlling terminal,
# see t/op/stat.t
if test \$tty = Y; then