- Use
prefix + :, then type incapture-pane -S -3000 + Return. (Replace -3000 with however many lines you'd like to save, or with - for all lines.) This copies those lines into a buffer. - Then, to save the buffer to a file, just use
prefix + :again, and type insave-buffer /home/{user}/filename.txt + return.
(By default Prefix is Ctrl+B.)