Wednesday, March 22, 2017

Re: [LINUX_Newbies] How to break a list

 

On Wed, Mar 22, 2017 at 9:15 PM, Michael msulli1355@gmail.com
[LINUX_Newbies] <LINUX_Newbies@yahoogroups.com> wrote:
> You could pipe it. Try 'ls | more' or 'ls | less' for more visual
> convenience. With less you can scroll through the listing using your
> keyboard arrow buttons. HTH

This is the correct answer. And if you want to take it a bit further:

# ls -C | less

The -C will force the output into columns. Normally, 'ls' will dump
output into columns, however, when you pipe it to less or more, it
outputs one line at a time in a single column. The -C overrides this
and 'ls' then outputs to the pipe in columns.

*(that's a gross simplification for what it's doing, but it's
explanatory enough for this).

you can also 'ls' wildcards if you know you're looking for certain
things in a dir...

ls *.xml to list only xml files.
ls *.jpg to list only jpg images.

and so forth.

ls colorado*.jpg to list only jpg images that begin with the string 'colorado'.

__._,_.___

Posted by: J <dreadpiratejeff@gmail.com>
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (5)

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.

To unsubscribe from this list, please email LINUX_Newbies-unsubscribe@yahoogroups.com & you will be removed.

.

__,_._,___

No comments:

Post a Comment