csh scripts on sys V question

Lawrence W. McVoy mcvoy at rsch.WISC.EDU
Thu Nov 20 03:34:14 AEST 1986


In article <787 at chinet.UUCP> megabyte at chinet.UUCP (Dr. Megabyte) writes:
>_IF_ I type "csh script".  Now, is there anyway for me to set up my 3b2 so that
>I can just type "script" and have the proper shell chosen, either Bourne or
>'C'? 

As I understand it the sh is started up to handle shell scripts, right?
In Bezerkeley Unix I think the kernel figures out what program to exec.
I don't see why the sh couldn't do this.  For instance, change the sh to
look at the first line and exec it if the line is of the form

'#' '!' <program name>

and program name != '/bin/sh' or 'sh'

Anybody have any problems with this?
-- 
Larry McVoy 	        mcvoy at rsch.wisc.edu, 
      		        {seismo, topaz, harvard, ihnp4, etc}!uwvax!mcvoy

"They're coming soon!  Quad-stated guru-gates!"



More information about the Comp.unix.questions mailing list