in reply to Spliting a log file into chunks and saving it into an array
This should do it,
That will leave the "-----" lines present. They can be removed with substr/index or a regex substitution.my @array = do { local $/ = ('*' x 66) . "\n"; my @tmp = <>; chomp @tmp; @tmp; };
substr $_, 0, 2 + length("\n") + index($_, "--\n"), '' for @array;
After Compline,
Zaxo
|
|---|