Remove lines from a file

Makes a copy of the file without the lines you don’t want:

[sourcecode]
cat file1.txt | grep -v “remove me I am a horrible line” > file2.txt
[/sourcecode]

Leave a Reply

Your email address will not be published. Required fields are marked *