Never been to DZone Snippets before?

Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

« Newer Snippets
Older Snippets »
Showing 1-1 of 1 total  RSS 

Remove comments from a file

Remove all comment lines from a file.

sed -e '/^#/d' $1 | more

or to output it to a new file
sed -e '/^#/d' $1 > $1.nocomments
« Newer Snippets
Older Snippets »
Showing 1-1 of 1 total  RSS