Search code examples
bashterminaloutputlinux-mint

Linux mint terminal output disappearing


enter image description hereI'm running a script on terminal and it is supposed to produce a long output, but for some reason the terminal is just showing me the end of the result and I cannot scroll up to see the complete result. Is there a way to save all the terminal instructions and results until I type clear.

The script I'm using has a loop so I need to add the output of the loop if Ill be redirecting the output to a file.


Solution

  • Depending on your system, the size of the terminal buffer may be fixed and hence you may not be able to scroll far enough to see the full output.

    A good alternative would be to output your program/script to a text file using:

    user@terminal # ./nameofprogram > text_file.txt

    Otherwise you will have to find a way to increase the number of lines. In some terminal applications you can go to edit>profiles>edit>scrolling tab and adjust your settings.