wytetygur has asked for the wisdom of the Perl Monks concerning the following question:
Hello,
I'm fairly new to perl and am trying to figure out how I can open a file, start reading it and replace the Macintosh style CR line terminators with the Unix style LF line terminator and then send that output directly to the Text::CSV module.
I'd like to do this without having to write the modified input to a file, then open that file to be process by Text::CSV.Is there a way in perl to parse the input stream and then feed the output directly to another function? Kind of like the pipe on the command line.
I've look through all the perldoc documentation but am not getting any clues to my answers.
Sorry, no code sample because I don't know how to start it yet
I'd really appreciate your help.Thanks, Allen
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Replace characters of input stream on the fly
by atcroft (Abbot) on Apr 08, 2011 at 05:02 UTC | |
Re: Replace characters of input stream on the fly
by apl (Monsignor) on Apr 08, 2011 at 10:37 UTC | |
Re: Replace characters of input stream on the fly
by anonymized user 468275 (Curate) on Apr 08, 2011 at 12:05 UTC |
Back to
Seekers of Perl Wisdom