What do you mean "wrap" it in a perl script?
If you want to make it a standalone perl script, it's just:
Code:
#!/usr/bin/perl -pi
s/(.*?)=\s+(.*?)\s+\#(.*?) Replace (.*?)\s+(.*)/$1= $4 \# $5 Replace $2 $3/
The command line parameters can go into the shebang (# is a sharp, ! is a bang) just fine. See perldoc perlrun to see why this works, and to see what -pi does.
Also, change /usr/bin to whatever "which perl" tells you.