3 ms·
For OSX, the command is: $ history | awk '{CMD[$5]++;count++;}END { for (a in CMD)print CMD[a] " " CMD[a]/count*100 "% " a;}' | grep -v "./" | column -c3 -s "
by Mizza 9y ago
For OSX, the command is:
$ history | awk '{CMD[$5]++;count++;}END { for (a in CMD)print CMD[a] " " CMD[a]/count*100 "% " a;}' | grep -v "./" | column -c3 -s " " -t | sort -nr | nl | head -n10
1 104 20.8% ls
2 72 14.4% cd
3 49 9.8% pip
4 25 5% a
5 21 4.2% j
6 19 3.8% z
7 19 3.8% vim
8 19 3.8% git
9 19 3.8% cat
10 12 2.4% sba
11 12 2.4% gs
13 8 1.6% ga
14 7 1.4% p
15 5 1% sof
`a` is an alias for ag, `j` is an alias for `autojump`, `sba` is an alias for `source env/bin/activate`. `gs` is git status, `ga` is git add, `p` is python, `sof` is soundscrape -of, `z` is zappa.