Use this command to view the top-5 most used commands on your Mac terminal
history | awk 'BEGIN {FS="[ \t]+|\\|"} {print $5}' | sort | uniq --count | sort --reverse --sort=numeric | head --lines 5
Use this command to view the top-5 most used commands on your Mac terminal
history | awk 'BEGIN {FS="[ \t]+|\\|"} {print $5}' | sort | uniq --count | sort --reverse --sort=numeric | head --lines 5