Skip to content

Instantly share code, notes, and snippets.

@gamefiend
Created January 6, 2012 13:16
Show Gist options
  • Save gamefiend/1570547 to your computer and use it in GitHub Desktop.
Save gamefiend/1570547 to your computer and use it in GitHub Desktop.
print top ten commands from bash history
history | awk '{a[$2]++}END{for(i in a){print a[i] " " i}}' | sort -rn | head
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment