I'm trying to invoke shell command (trivial-shell:shell-command "pwd") and it tries to create temporary file inside current directory, which happens to be "/", with a shitty code like (loop thereis (open (format nil "TEMP-~D" (random 100000))
:direction :probe :if-exists nil
:if-does-not-exist :create)
Of course that results into "error opening #P"/TEMP-12698": Permission denied"
That is why we cant have nice things. Everything will be wrong and fail. I hate you all!
Name:
Anonymous2012-03-07 6:22
Do you believe me?!! Lisp has no fucking standard way to create a tmp file!
Name:
Anonymous2012-03-07 6:23
>>1 (random 100000)
And what if one happens to open more than 100000 files?
You're doing it so wrong. Read the relevant documentation. Besides, do you even need a temporary file? You can make in-memory streams quite easily and have those streams backed by files if you want.