ls

Syntax

ls [<OPTIONS>] [<FILE-NME>]

Description

This command lists directory contents.

Command context

Service OS (SVOS>)

Parameters

<OPTIONS>

Specifies options for the command.

-1

Shows one-column output.

-a

Shows entries which start with a period (.).

-A

Shows output similar to -a, but excludes a period (.) and a double period (..).

-C

Shows output list by columns.

-x

Shows output list by lines.

-d

Shows listing of directory entries instead of contents

-L

Follows symlinks.

-H

Follows symlinks on the command line.

-R

Recurse.

-p

Appends a slash (/) to directory entries.

-F

Appends an indicator to entries. An indicator can be as an asterisk (*) or slash (/) or equal sign (=) or at sign (@) or pipe (|).

-l

Shows the output in a long listing format.

-i

Shows the list inode numbers.

-n

Shows a list of numeric UIDs and GIDs instead of names.

-s

Shows a list of allocated blocks.

-e

Shows in one column a list with the full date and time.

-h

Shows list sizes in human readable format (1K, 243M, 2G) with a one-column output.

-r

Shows in one column a sort in reverse order.

-S

Shows in one column a sort by size.

-X

Shows in the output sort by extension.

-v

Shows in one column a sort by version.

-c

With -l, it shows a sort in one column by ctime.

-t

With -l, it shows a sort by mtime.

-u

With -l, sort by atime.

-c

With -l, it shows a sort in one column by ctime.

-w <N>

Assumes that the terminal has the number of columns wide as specified by <N>.

--color[={always | never | auto}]

Controls color in the output.

<FILE-NAME>

Specifies the name of the file to list.

Authority

Administrators

Example

Listing directory contents:

SVOS> ls -la /nos
drwxr-xr-x    3 0        0             4096 Nov 21 03:19 .
drwxr-xr-x   11 0        0              220 Nov 21 03:21 ..
drwx------    2 0        0            16384 Nov 21 03:20 lost+found
-rwxr-xr-x    1 0        0        205957424 Nov 21 03:19 primary.swi
SVOS>