Remove Even Lines
Tagged with: awk, command, even, line, Linux
Sunday, April 27th, 2008 11:04 PM
This command removes all the even lines from the file given as the argument
cat example.txt|awk 'NR%2==1'
This command removes all the even lines from the file given as the argument
cat example.txt|awk 'NR%2==1'