Wow ! I've just figured out the best execve(2) Shebang line for pil scripts:

    $ cat myscript.l
#!/usr/bin/pil -script (car (nth (argv) 1)) (nth (argv) 2)
(let (ars (car (rest)))
 (prinl (car (nth (file) 2)) " ARGS: " (sym ars))
)
(bye)

    $ chmod +x myscript.l

    $ ./myscript.l
myscript.l ARGS: NIL

    $ ./myscript.l 1 2 3
myscript.l ARGS: ("1" "2" "3")


 Awesome! I've been missing something like this for ages.

 I'd suggest adding documentation of this to the 'ref.html'
 'Invocation' section .

Best Regards,
Jason

-- 
UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe

Reply via email to