LS(1) LS(1) NAME ls, lc - list files SYNOPSIS ls [ -lpmnqduntscrFT ] [ file... ] lc [ -lpmnqduntscrFT ] [ file... ] DESCRIPTION Ls lists the named files in an order and format determined by its options. The options determining the output format are: -l Produce output in long format. The information given in each column is as follows: 1. The permission mode of the file. This is for- matted as 11 characters; the first is `d' if the file is a directory, `a' if the file is append-only, `A' if it is an authentication file, or `-' otherwise. The next character is `l' if the file is exclusive-use, or `-' otherwise. The remaining characters are in three groups of three, each representing one permission bit. Each character is either `r' (read permission), `w' (write permission), `x' (execute permission) or `-' (no permis- sion). The three groups represent permis- sions granted for that file to the file's owner, members of the file's group and any- body else respectively. 2. The device type (this is the `#' device let- ter for local devices or `M' for files mounted over a Styx connection). 3. The device instance number (this distin- guishes between separately mounted instances of the same device). 4. The file's owner. 5. The file's group. 7. The size of the file in bytes. 8. The date and time the file was last modified (see also the -u and the -e options). 9. The name of the file. Page 1 Plan 9 (printed 11/18/24) LS(1) LS(1) -m Print the name of the user who most recently modi- fied the file. -q Print the file's qid (see sys-stat(2)) at the beginning of each line; the printed fields are in the order path, version, and type. -u Applicable only to the -l and -t options: causes time-sorted listings to be listed by time of last access, and the access time to be printed in long-format listings instead of the modification time. -e Applicable only to the -l and -u options: causes the time to be displayed as seconds since the epoch. -p Print each filename as a bare name, without the name of the containing directory. The other options relate to the order in which the listed files are printed, and which files are selected. Usually, each file that is a directory has its contents printed. The -d option causes the directory itself to be listed. In a union directory, it is possible for there to be two or more instances of a file with the same name. The -c option causes only the first one occurring to be listed. The options relating to ordering are: -n Do not sort the files at all. -t Sort by modification time (most recent first) or access time if the -u option is also specified. -s Sort by size (smallest first). -r Reverse the sort order. -F Add the character / after all directory names and the character * after all executable files. -T Print the character t before each file if it has the temporary flag set, and - otherwise. Lc is the same as ls, but sets the -p option and pipes the output through mc(1). SOURCE /appl/cmd/ls.b /dis/lc SEE ALSO Page 2 Plan 9 (printed 11/18/24) LS(1) LS(1) readdir(2), mc(1) Page 3 Plan 9 (printed 11/18/24)