To my knowledge this can't be done purely in LISP, you will basically need your routine to create a SCRIPT file, run it, then the SCRIPT file will need to run another LISP routine to delete the script file.
I could be wrong, but this is my understanding on how this all works.