in reply to Re^2: Write to multiple files according to multiple regex
in thread Write to multiple files according to multiple regex
The conditional to print looked rather fishy, but I forgot about it. Try:
print {$filehandles[$i]} $line - if (/$regex[$i]/../^END_OF_BLOCK/); + if ($line =~ /$regex[$i]/../^END_OF_BLOCK/);
or did you already do exactly that? Please show your updated code.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Write to multiple files according to multiple regex
by Foodeywo (Novice) on Jul 21, 2015 at 13:03 UTC |