Skip to content

Instantly share code, notes, and snippets.

@xatier
Last active December 18, 2015 02:48
Show Gist options
  • Save xatier/5713133 to your computer and use it in GitHub Desktop.
Save xatier/5713133 to your computer and use it in GitHub Desktop.
$ history | awk '{CMD[$2]++;count++;} END { for (a in CMD )print CMD[ a ]" " CMD[ a ]/count*100 "% " a}' | grep -v "./" | column -c 3 -s " " -t | sort -nr | nl | head -n 10
1 229 15.0956% vim
2 208 13.7113% sudo
3 178 11.7337% ls
4 158 10.4153% cd
5 84 5.53724% lua
6 51 3.3619% pacman
7 49 3.23006% git
8 36 2.3731% htop
9 28 1.84575% startx
10 28 1.84575% rm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment