Read all of the terminal command history in OS X
All of your history is stored in ~/.bash_history
, where both reverse-i-search
and the up/down keys use. That file is regularly pruned, but if you followed the guide in your link, the .bash_history
file will practically never be pruned.
Personally, I would prefer to do it in a simpler way and print everything, instead of checking the latest session which doesn't cover all Terminal windows and all commands.
Get a full history
cd ~/.bash_sessions
cat *.historynew *.history
If you want to sort by session date
cd ~/.bash_sessions
cat `ls -tr *.historynew *.history`