[Subject Prev][Subject Next][Thread Prev][Thread Next][Subject Index][Thread Index]

Re: peculiar problem with bash



On Fri, 14 Jul 2000, Sivakumar Shanmugasundaram wrote:
> hi,
> 
> i dont think so. i believe it is a problem with the
> shell directive in the first line of the script.
> if it has, say, #!/bin/bash, make sure there IS a
> /bin/bash (or whatever the .sh file has)
> hope this helps.


To Siva:


No. I tried all the variants.


> PS: i am an alumni of annauniv. '92 CSE. what kind of
> linux setup do we have now


I am a student of MIT campus of Anna Univ..  So I don't know much about
the CEG campus settings.  May be george or manisridhar know things better
than me. 

***********************************
To George samuel:

Excellent george.  Exactly that is the problem with my file.  after seeing
your mail i did the octal dump and found the sequence \r\n throughout the
file.  thanks a lot.  Now it is working perfectly.

** mks ** 


 > --- Athena <linux@xxxxxxxxxxxx> wrote:
> >       The problem is quite simple. There is an extra
> > '\r' at the end of
> > the line. You can find it by using 
> >           od -c filename
> >           If you see '\r' then you know the problem.
> > I have had this
> > problem with some scripts. ( Happens when you use a
> > Windows/Dos editor to
> > code your scripts )
> >           For fixing it use
> >            tr -d '\r' <filename  >newfilename
> >            and run the script using sh newfilename
> > 
> > -George Samuel 
> > 

---
Visit our home page at: www.chennailug.org
Send e-mail to 'ilugc-request@xxxxxxxxxxxxxxxxxx' with 'unsubscribe' 
in either the subject or the body to unsubscribe from this list.