should skip everything up to the datestamp
oops, missed the "---" line. Adding one line of code addresses that:
my $position_rolled = 0; while (<$fh>) { chomp; if ($position_rolled) { next if !/^... .\d 20\d\d/; $position_rolled = 0; $position_rolled_into = $_; } elsif ($_ eq 'Position has rolled into') { $position_rolled = 1; } ... }
In reply to Re^3: Parsing/regex question
by ikegami
in thread Parsing/regex question
by vxp
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |