Tag: awk
Sort by Line Length
April 14, 2009
Sort file by line length. Original Article… cat /etc/passwd | awk ‘{print length, 0}’ | sort -n | awk ‘{1=””;…
Convent Ico to Gif
May 26, 2008
This will convert all the ico files in the folder to gif. It uses the final frame of the ico…
Remove Even Lines
April 27, 2008
This command removes all the even lines from the file given as the argument cat example.txt|awk ‘NR%2==1’
Fish Shell Command History Meme
April 16, 2008
Use this command if you want to know your command usage stats in the fish shell. grep -v “^\#” “.config/fish/fish_history”|awk…
Better Way to find Process ID of an Application in Linux
September 14, 2007
A better way to get the process id of an application. I recommend giving an alias for this command… ps…
Fetch columns of Output using Awk
July 9, 2007
One can use awk to get a specific column from a command output… First column of the command date|awk ‘{print…
Using Awk
May 11, 2007
Simple uses for awk Get the second column from the output ps aux | awk ‘{print $2}’ Use a different…
Recent Comments