[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Scheme shellscripts

In article <various@many.sites> many people write shell scripts with
lines like:

	echo > .tmp '(set! $* (quote ('$*')))'

in them. This has one nasty problem - try doing "cd /; <scheme-program>".
You'll find (well, you ought to find) that it dies - you can't create
the scratch file you want. Of course, if two people are in the
directory you're running in and running that command, you'll have
probles too.

Instead, try doing:

	echo > /tmp/runscheme.$$ '(set! $* (quote ('$*')))'

This creates a file in /tmp with the process id of the shell executing
the script in it's name. That solves both problems at once.


My feet are set for dancing,				Mike Meyer
Won't you turn your music on.				mwm@berkeley.edu
My heart is like a loaded gun,				ucbvax!mwm
Won't you let the water run.				mwm@ucbjade.BITNET