Multiline shebang: Difference between revisions
Content added Content deleted
m (J: more diagnostic info) |
(→{{header|TXR}}: Added zkl) |
||
Line 515: | Line 515: | ||
arg[3]="3" |
arg[3]="3" |
||
$</pre> |
$</pre> |
||
=={{header|zkl}}== |
|||
zkl has a variant of the here doc that means ignore the doc, as in "#if 0" but more so. But that doesn't mean a shell has to ignore it. |
|||
File foo.zkl (the .zkl extension is needed): |
|||
<lang zkl>#!/bin/sh |
|||
#<<<# |
|||
echo "A shell script in a zkl program ($0)" |
|||
echo "Now run zkl <this file> with Hello World as args" |
|||
zkl $0 Hello World! |
|||
exit |
|||
#<<<# |
|||
println("The shell script says ",System.argv[2,*].concat(" "));</lang> |
|||
{{out}} |
|||
<pre> |
|||
$ ./foo.zkl |
|||
A shell script in a zkl program (./foo.zkl) |
|||
Now run zkl <this file> with Hello World as args |
|||
The shell script says Hello World! |
|||
$ |
|||
</pre> |
|||
{{omit from|BASIC}} |
{{omit from|BASIC}} |