I've been trying to learn Common Lisp with SBCL and I've ran into issues executing my code. Everything works fine using sbcl --script exec.lisp
(regardless of if I have specified a shebang line) but I can't seem to execute the same file with a shebang line directly as ./exec.lisp
. While I've most likely misunderstood something the manual does from my understanding imply that this should be possible. My exec.lisp
script looks identical to the one in the example (and it has been given executable privileges chmod a+x exec.lisp
)
#!/usr/local/bin/sbcl --script
(write-line "Hello, World!")
but instead of the desired output I receive :
$ ./exec.lisp
./exec.lisp: line 2: write-line: command not found
I've made sure that the path to sbcl
is correct)
EDIT: I'm using mac OS.
chmod +x
)? If Windows, issbcl.exe
in your system PATH? β Furcula