Tong's Work Notes
The learning process
Thursday, June 16, 2016
Remove comments and empty line from a text file
cat <file_name> | grep -v "^#" | grep -v '^$'
This command will remove empty lines and any line starts with #.
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment