[ale] dos file in linux?? WTF?

tewkewl at mindspring.com tewkewl at mindspring.com
Wed Dec 12 18:43:16 EST 2001


You guys were absolutely right.  I compiled dos2unix and ran it on the file and presto changeo, the file magicaly shrunk!  (I can only assume it took the linfeeds out.  and the script runs fine now...

now if somebody can explain to me why the hell bash cares enough about linefeeds to tell me the file doesn't exist when it plainly does! :)

-Patrick


Michael Golden <naugrimk at yahoo.com> wrote:
> On Wed, 2001-12-12 at 18:14, tewkewl at mindspring.com wrote:
> Hey guys...
> 
> How does linux/vi know that a file is considered to be a 'dos' file?
> it really never was a dos file...it was a script written on an hp box...but during the move (tar/zip) when we run it on linux, it reports "bash: ./secng.sh: No such file or directory"
> 
> when the file is plainly there and with execute permissions.
> 
> when I VI the file, vi reports [DOS] at the bottom where it has the file name.  Anybody have a clue?


My only guess on how it could do that is to check whether lines end with
just CR or CR/LF. You can use the dos2unix utility to fix that if that
is the problem. If that's not it then I don't know. :-/

Michael 

---
This message has been sent through the ALE general discussion list.
See http://www.ale.org/mailing-lists.shtml for more info. Problems should be 
sent to listmaster at ale dot org.



---
This message has been sent through the ALE general discussion list.
See http://www.ale.org/mailing-lists.shtml for more info. Problems should be 
sent to listmaster at ale dot org.






More information about the Ale mailing list