diff options
author | Marc Cornellà <marc.cornella@live.com> | 2020-09-26 12:17:12 +0200 |
---|---|---|
committer | Marc Cornellà <marc.cornella@live.com> | 2020-09-26 12:17:12 +0200 |
commit | caff704f41d7a8cd01aa54b1202d6e3123e33fe6 (patch) | |
tree | 582cf552cffe526baef6fa217b0df84233bd1fd8 | |
parent | bcc859e012a8f259971d1fd531535a261838c0c4 (diff) | |
download | zsh-caff704f41d7a8cd01aa54b1202d6e3123e33fe6.tar.gz zsh-caff704f41d7a8cd01aa54b1202d6e3123e33fe6.tar.bz2 zsh-caff704f41d7a8cd01aa54b1202d6e3123e33fe6.zip |
lib: clean up zsh_stats function
-rw-r--r-- | lib/functions.zsh | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/functions.zsh b/lib/functions.zsh index 4bc533b7a..58f0e3fb0 100644 --- a/lib/functions.zsh +++ b/lib/functions.zsh @@ -1,5 +1,7 @@ function zsh_stats() { - fc -l 1 | awk '{CMD[$2]++;count++;}END { for (a in CMD)print CMD[a] " " CMD[a]/count*100 "% " a;}' | grep -v "./" | column -c3 -s " " -t | sort -nr | nl | head -n20 + fc -l 1 \ + | awk '{ CMD[$2]++; count++; } END { for (a in CMD) print CMD[a] " " CMD[a]*100/count "% " a }' \ + | grep -v "./" | sort -nr | head -n20 | column -c3 -s " " -t | nl } function uninstall_oh_my_zsh() { |