Yes, but please mention something about '(script ...) in the
main 'ref' "Invocation" Section.  It took me a long time to find!

On 06/08/2023, Alexander Burger <picolisp@software-lab.de> wrote:
> On Sun, Aug 06, 2023 at 07:20:40AM +0100, Jason Vas Dias wrote:
>> 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)
>
> Just for the records, note that
>
>    (car (nth Lst 1))
>
> is the same as
>
>    (get Lst 1)
>
> which is the same as
>
>    (car Lst)
>
> And
>
>    (nth Lst 2)
>
> is
>
>    (cdr Lst)
>
>
>>  Awesome! I've been missing something like this for ages.
>
> I use it sometimes to set up proper namespaces:
>
>    #!/usr/bin/pil -symbols 'ap 'pico
>
>
>>  I'd suggest adding documentation of this to the 'ref.html'
>>  'Invocation' section .
>
> There are examples for this around (though not very prominent),
> for example in
>
>    https://picolisp.com/wiki/?serversentevents
>
> there is
>
>    #!/usr/bin/pil -load "@lib/http.l" "@lib/xhtml.l"
>
> ☺/ A!ex
>
> --
> UNSUBSCRIBE: mailto:picolisp@software-lab.de?subject=Unsubscribe
>

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

Reply via email to