Path: utzoo!attcan!uunet!peregrine!elroy!ames!mailrus!uflorida!gatech!emcard!stiatl!meo
From: meo@stiatl.UUCP (Miles O'Neal)
Newsgroups: comp.unix.questions
Subject: Re: Bourne Shell Comments Problem
Summary: Its invoking csh!
Keywords: Bourne Shell UNIX Problem
Message-ID: <375@stiatl.UUCP>
Date: 22 Sep 88 13:04:34 GMT
References: <292@dsacng1.UUCP>
Organization: Sales Technologies Inc., Atlanta, GA
Lines: 21

In article <292@dsacng1.UUCP>, nab1382@dsacng1.UUCP (Dick Hauser) writes:
> The comment indicator (i.e #) is
> in position 1 of the first record of the file.  The comment line
> was followed by a read command for a varibale.  When the shell  
> was executed using "sh -x shellname", everything worked.  But
> when the shell is executed, and execution is not traced, an error
> message "read not found" is displayed.

A comment indicator in column1, line 1, indicates the script is
a csh script instead of sh. Bourne shell (sh) scripts with comments
at the top require a blank line (or anything other than a comment)
on the first line. Since read is built into sh, and csh uses a
different mechanism for reading input, csh could not find a read
program in your path to invoke.

As the above implies, any script that does not have the comment starting
in column 1, line 1, will default to sh.

I am not familiar with ksh (barbarian that I am), so I don't know how
that fits into the scheme of things. I also don't know what happens
on System V implementations without a vendor-added or PD csh.