Jamie Risk wrote:
> Okay, I do know that binary transfer of a text file between DOS and
> Unix systems is a non-non, but my Samba setup isn't that
> discriminating.
>
> Perl is running on a Unix platform, and 'chomp' isn't quite up to the
> task of removing CR (ASCII '\r' or 0x0D).
It is if you
>
>
> Okay, I do know that binary transfer of a text file between
> DOS and Unix
> systems is a non-non, but my Samba setup isn't that discriminating.
>
> Perl is running on a Unix platform, and 'chomp' isn't quite
> up to the task
> of removing CR (ASCII '\r' or 0x0D).
> So I tried:
> s/(.+)
> So I tried:
> s/(.+)[ \t\n\r]*/$1/
> but those tricky little CR are still there. Even
> s/(.+)[ \t\n\r\015]*/$1/
> still eludes me.
And then I tried:
s/([^\n\r]+)[ \t\n\r]*$/$1/;
which does work, but seems overly finicky to get rid of BG's legacy. Is
there a better way?
--
To unsubscr
Okay, I do know that binary transfer of a text file between DOS and Unix
systems is a non-non, but my Samba setup isn't that discriminating.
Perl is running on a Unix platform, and 'chomp' isn't quite up to the task
of removing CR (ASCII '\r' or 0x0D).
So I tried:
s/(.+)[ \t\n\r]*/$1/
but those