So I was thinking of doing something like open the file, loop through it and chomp out the newlines and stuff that all into a variable. Then do a regex (or probably more than one) on that variable to replace the chars. Then finally write that variable out to the output file.
The thing is we're looking at a pretty large file and stuffing that much data into a single variable seems like a pretty good way of crashing my box.
So are there any better ways of doing this?
Thanks in advance.
In reply to scalable chomping by xorl
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |