MacOS – Infinite scrollback in Terminal (Yosemite)

macossettingsterminal

I would like to save the scrollback history in terminal basically forever.

I don't mean bash history, I mean all the text that ever scrolled past in the terminal, not just the commands entered.

I found the files where they are stored in:

~/Library/Saved Application State/com.apple.Terminal.savedState/

But I would like the data to persist beyond current sessions, after I close the terminal, the data persists indefinitely.

Also, is there a tool that will let me read those data files?

Thanks for any info

Best Answer

Here's an option for running a script on startup to append everything to a log file. Searching a text file will likely be a better option than manually scrolling up in Terminal, or filling up a buffer.

http://hints.macworld.com/article.php?story=20120507163311559