in reply to Re: Parsing Pegasus email boxes
in thread Parsing Pegasus email boxes
{ open( IN, "pegasus.file" ) or die $!; local $/ = "\x1a"; # change the input record separator while (<IN>) # $_ now contains one whole message, { # up to and including \x1a # do what you want with the message # including, if you like: @lines = split /\n/; # work on lines # or you could strip off the pegasus header stuff # and treat the remainder as if it were vanilla email # (just like you'd get with common unix mail tools) } } # record separator now reverts back to default
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: Parsing Pegasus email boxes
by peterr (Scribe) on Nov 17, 2003 at 03:15 UTC |