Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!mailrus!shadooby!samsung!uakari.primate.wisc.edu!ames!orion.arc.nasa.gov!gahooten From: gahooten@orion.arc.nasa.gov (Gregory A. Hooten) Newsgroups: comp.unix.questions Subject: Another sed question. Message-ID: <37091@ames.arc.nasa.gov> Date: 1 Dec 89 18:50:48 GMT Sender: usenet@ames.arc.nasa.gov Reply-To: gahooten@orion.arc.nasa.gov (Gregory A. Hooten) Organization: NASA Ames Research Center, Moffett Field, CA Lines: 24 I ran across a shell script that had this as the first line of code. ------------------------------------------------------------- #!/bin/sed d1 Some bunch of text for several lines. ------------------------------------------------------------- What it did was to delete the line starting with the # sign and display all of the text that was in the file. My questions are, why do it this way in- stead of using echo? Why is the # line considered line 1, when it was used to start the command in the first space, it seems to me that the line would have already been sent to the terminal to start the sed, and so would not be deleted? Could someone explain the process of this part of the sed command and script files? Thanks Greg Hooten GAHOOTEN@ames.arc.nasa.gov