Suppose I have a file named 1.sb with this content:
If I invoke it as
How do I get the name of the script file itself (1.sb)?
(I got no takers on stackoverflow for this question.)
Code:
#!/usr/local/bin/sbcl --script
(prin1 sb-ext:*posix-argv*) (terpri)
1.sb a b c
I get this output:
Code:
("/usr/local/bin/sbcl" "a" "b" "c")
(I got no takers on stackoverflow for this question.)