When converting oneliners to Perl code, there are two ways. The first is to convert the onliner to a full Perl program:
perl -MO=Deparse -pi.bak -e s/$search(?=,)\/$replace/g
The alternative is to use File::Inplace, which implements the -p-loop as a Perl module.
In reply to Re: Solve the large file size issue
by Corion
in thread Solve the large file size issue
by Vkhaw
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |