Difference between revisions of "Ls"
Jump to navigation
Jump to search
Tags: Mobile web edit, Mobile edit |
Tags: Mobile web edit, Mobile edit |
||
Line 12: | Line 12: | ||
** <code>ls -lhS</code> | ** <code>ls -lhS</code> | ||
** <code>ls -lR | grep '^-' | sort -rnk5</code> (sort will not work if ls is used with -h) | ** <code>ls -lR | grep '^-' | sort -rnk5</code> (sort will not work if ls is used with -h) | ||
− | ** Including full path: <code>ls -ld $([[find]] ./) | [[sort]] -rnk5</code> | + | ** Including full path: <code>ls -ld $([[find]] ./) | [[sort]] -rnk5 | more</code> |
:::-su: /bin/ls: Argument list too long | :::-su: /bin/ls: Argument list too long | ||
::: -d list directories themselves, not their contents | ::: -d list directories themselves, not their contents |
Revision as of 17:29, 20 April 2020
ls
is a command to list files, directories and symbolic links in Linux and Unix-like operating systems include in the coreutils
package in Ubuntu.
Linux Examples
ls
ls -l
ls -lh
ls -lhaR
- One line listing with sizes using ls and find:
ls -ldh $(find /path/to/search/)
- Sort by size:
- -su: /bin/ls: Argument list too long
- -d list directories themselves, not their contents
Related commands
See also
- File system,
du, df, find, ls, mkdir, touch, locate
du, du -hs
, Disk space usage,df
,ls
,tree
,find
,docker system df
,journalctl --disk-usage
, No space left on device, ENOSPC,sar -F
,growpart
,resize2fs
, ncdu, duf, dua-cli
Advertising: