Linux.com

Home Learn Linux Linux Answers Desktop Can you pause the ls command?
Answers
  • ls | less
    That will allow to scroll up and down the list.
    I do hope that helps.

    Answered by John Rowland
    2 years ago
    0 2
  • You can simply type ls | more

    Answered by Leonardo
    2 years ago
    0 1
  • To view long output from utilities like ls, you must pipe the output into a pager, such as more, less, or most: `ls | less`. The "|" (pipe) sends, or pipes, standard output from the command on the left (ls) into the standard input of the command on the right (less). Press the spacebar to advance the output of the pager. Press the "q" key to quit the pager. Try `man less` for more information.

    Answered by Brandon Carpenter
    2 years ago
    0 2
  • use the more command like: ls -l | more (pipe sign)
    or u can scroll the output both up and down one line at a time, try this command: ls -l | less (here ctrl+c does not work, while u have to press q to exit)

    Answered by Rechil Colin
    2 years ago
    0 1
  • ls | more

    Answered by Abdul Aziz Tsaqieb
    2 years ago
    0 1
  • For this you use the "less" o "more" command and you connect them with the pipe character "|" so the command should be "ls | less" or "ls | more" for me, "less" is better.

    Answered by raluxs
    2 years ago
    0 1
  • ls | more

    Answered by Srinivas
    2 years ago
    0 1
  • Pipe the output of ls command to more command. So it should look like this ls | more. Say, if you're trying to see what's inside /home/user/Documents you can type ls /home/user/Documents | more. This will let you see the contents of Documents page by page, or line by line.

    Answered by Sevv
    2 years ago
    0 1
  • You can't pause it per say, however, you can pipe it through more/less

    Generally, I'll do a "ls | less"
    This will allow you to essentially "pause" the output, scroll through it, and even perform a search if necessary.

    Hope that helps!

    Answered by Adam S
    2 years ago
    0 0
  • Add "|more" at end (without quotes)

    Answered by Emery
    2 years ago
    0 0
  • try this "ls -l |more"

    Answered by René Kvist
    2 years ago
    0 0
  • Hey Charles,
    You can certainly "pause" the ls command. All you have to do is use ls in conjunction with the less command. So for example you'd type "ls | less" without the quotes. Also to create the | symbol (pipe) just hold shift and hit the key above enter. You can also look at my site for a little more information about ls and various other commands. www.cmdlist.com

    Hope this helps,
    Adam

    Answered by adam balla
    2 years ago
    0 0
  • ls | more

    Answered by Christer Rosenquist
    2 years ago
    0 0
  • In the command prompt type:

    #ls | less

    This will force ls to list content one screen-section at a time.

    Answered by Istimsak Abdulbasir
    2 years ago
    0 0
  • Try this:

    ls | less

    Answered by Brian Kuebler
    2 years ago
    0 0
  • ls -l | more

    Answered by Jason Bloink
    2 years ago
    0 0
  • Pipe the output through a pager. If you have the PAGER variable defined, use:

    ls | "$PAGER"

    If not, use either less or more:
    ls | more
    ls | less

    Answered by Chris F.A. Johnson
    2 years ago
    0 0
  • Why not just scroll up and down with: SHIFT + PgUP/pgDOWN ?

    You could redirect the output to a file as well:
    ls > output_file

    Answered by Marc Deop
    2 years ago
    0 0
Please register/login to answer this question. Click here to login
Similar Questions Found
Questions from category Desktop

Community Answers - Search


Who we are ?

The Linux Foundation is a non-profit consortium dedicated to the growth of Linux.

More About the foundation...

Frequent Questions

Join / Linux Training / Board