home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.unix.ultrix
- Path: sparky!uunet!stanford.edu!kronos.arc.nasa.gov!iscnvx!lange
- From: lange@iscnvx.lmsc.lockheed.com (Alex Lange)
- Subject: First Line Comments in Scripts
- Message-ID: <1992Sep4.183234.29076@iscnvx.lmsc.lockheed.com>
- Reply-To: lange@lmsc.lockheed.com
- Organization: Lockheed Missiles & Space, Sunnyvale CA USA
- X-Newsreader: Tin 1.1 PL4
- Date: Fri, 4 Sep 92 18:32:34 GMT
- Lines: 22
-
- It seems as though ULTRIX 4.2 insists that all shell scripts
- run in the C shell, ignoring the $SHELL variable.
-
- My $SHELL is /bin/sh. My scripts have first lines that look like this:
-
- # @$-r name of job
- set -x
-
- (These are directives for the NQS batch system on some machines.)
- I can run these scripts interactively or in batch on non-ULTRIX
- machines because the directive looks like a comment to most UNIXes.
-
- But ULTRIX runs these scripts in csh. I have to add #!/bin/sh
- to force what should be my default shell!
-
- The same behavior happens with commented SCCS files (with
- # @(#) on line one).
-
- Is this a well known flaw in ULTRIX (I haven't located the FAQ
- for this group)? or something peculiar with my system?
-
- Alex Lange
-