Hacker News new | ask | show | jobs
by 65a 4774 days ago
My history seems to have timestamps on FreeBSD-CURRENT running bash.

I had to use

history | sed "s/^[0-9 ]//" | sed "s/ | */\n/g" | awk '{print $3}' | sort | uniq -c | sort -rn | head -n 100 > commands.txt