🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.bash.bug
Article #1169

BASH and Bourne Shell scripts

#1169
From: Brian Fox
Date: Wed, 21 Feb 1990 05:15
27 lines
1613 bytes
   Date: 9 Feb 90 23:53:27 GMT
   From: milano!peyote!galew_a@cs.utexas.edu  (Andy Galewsky)
   Organization: Capital Area Central Texas Unix Society, Austin, TX
   Sender: bug-bash-request@prep.ai.mit.edu

   I hope I'm not just being stupid (it has happened before) but - when I am
   running BASH-1.04 and I try to execute a Bourne shell script - I can't get 
   /bin/sh to execute it -- BASH tries to do it. I have tried putting #!/bin/sh
   as the first line of the shell script - but BASH continues to try to execute
   it - itself. It doesn't seem right that I have to throw away all of my old
   shell scripts in order to run BASH. This is probably not a BASH bug - but just
   a problem with my understanding of how this works.

			   Thanks 
			    Andy Galewsky
			   Clinical Resource Systems
			   peyote!sneffels!andy
			   galew_a@peyote.cactus.org


System V machines don't pay attention to #! in the first line.  Their
fault, not yours.  If the system call exec () didn't exec the file, then
bash assumes that the file is a bash script.  Not a bad assumption, and
in fact, the same assumption that /bin/sh makes.

Brian
Technical Details
Message-ID: <9002210515.AA12755@sbphy.Ucsb.EDU>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!tut.cis.ohio-state.edu!sbphy.mit.edu!bfox
References: <376@peyote.cactus.org>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!tut.cis.ohio-state.edu!sbphy.mit.edu!bfox
From: bfox@sbphy.mit.edu (Brian Fox)
Newsgroups: gnu.bash.bug
Subject: BASH and Bourne Shell scripts
Message-ID: <9002210515.AA12755@sbphy.Ucsb.EDU>
Date: 21 Feb 90 05:15:40 GMT
References: <376@peyote.cactus.org>
Sender: daemon@tut.cis.ohio-state.edu
Reply-To: bfox@ai.mit.edu
Distribution: gnu
Organization: GNUs Not Usenet
Lines: 27