At 11:34 AM +1200 2/4/01, hciR nellA wrote:
> iH
> 
> Thanks. that was it.
> 
> This seems like a real "turkey", since the script worked under OS 9 as a 
> Mac file but not after moving it to OS X.
> 
> thanks again
> 
> On Sunday, April 1, 2001, at 03:23 PM, Ian Ragsdale wrote:
> 
> > My guess is that it is a line endings problem - I get this error under 
> > most unix systems if I use a file with macintosh line endings.  Can 
> > whatever editor you're using translate the line endings to unix?
> >

I joined this list while I was fooling with my first OSX perl script, and hit the same 
problem. Actually it was the line endings in the data I was filtering (a 
comma-delimited file), rather than the script.

I toyed with setting the end-of-record separator ($/) in the script, but in the end I 
just did this:

        cat ~/data.txt | tr "\r" "\n" > /tmp/data.txt
        mv /tmp/data.txt ~/data.txt

Later I put that in a shell script.

God, it's good to back on a UNIX system. OSX really is the best of both worlds, and 
it's only going to get better.

:o)

Cheers,

Andrew Duncan
----------------------------------------------------------------------
voice:    +64 9 623 2926
web:      http://web.webwerks.co.nz/
It doesn't look ready for prime time yet because it isn't ready for
prime time yet... if it was, it wouldn't be DP4, it'd be v1.0. - Orbit
----------------------------------------------------------------------


Reply via email to