I often pipe commands to less
in order to read through the output (e.g. compiler errors).
MyCommand | less
This is great because it makes trawling through large amounts of output easy, but when I exit less
the output is gone. How can I make the output still visible after quitting less?
This question differs from Is there a way to redirect a program's output and still have it go to stdout? because that question relates to output to a text file via tee
, which, as far as I know, doesn't provide a facility to split output between less
and stdout
.
tee
command. I am not sure what the rules are regarding this situation but I don't think marking this as a duplicate would benefit the community unless the answer to that question is reviewed. – quant Aug 12 '14 at 23:19less
; namely, how to get it to leave the displayed text in the console's scrollable display history buffer. ... P.S. Arman: You might want to [edit] your question and retag is as a/less
question. – G-Man Says 'Reinstate Monica' Aug 12 '14 at 23:24