[TAG] 2cent tip
ben at linuxgazette.net
Fri Jun 6 20:30:15 MSD 2008
On Fri, Jun 06, 2008 at 09:27:34PM +0530, Kapil Hari Paranjape wrote:
> On Fri, 06 Jun 2008, Thomas Bonham wrote:
> > I thought I would sure this little perl script that will remove the
> > comments out of a configuration file.
> Why not just the following?
> grep -v '^#.*' < input > output
Or perhaps 'egrep -v '^[ ]*(#|$)' < input > output' (the stuff
between the brackets is a space and a tab) - but that still doesn't fix
the original file.
* Ben Okopnik * Editor-in-Chief, Linux Gazette * http://LinuxGazette.NET *
More information about the TAG