Linux/ls
< Linux
ls
List all files:
ls -la
Reverse sort:
ls -lr
Color: (dir blue, folders white)
ls --color
Time:
ls -lt ls -ltr
-c with -lt: sort by, and show, ctime (time of last modification of file status information)
with -l: show ctime and sort by name otherwise: sort by ctime
-t sort by modification time
-u with -lt: sort by, and show, access time with -l: show access time and sort by name
otherwise: sort by access time
--full-time
like -l --time-style=full-iso
--time=WORD
with -l, show time as WORD instead of modification time: atime -u, access -u, use -u,
ctime -c, or status -c; use specified time as sort
key if --sort=time
--time-style=STYLE
with -l, show times using style STYLE: full-iso, long-iso, iso, locale, +FORMAT.
FORMAT is interpreted like ‘date’; if FORMAT is FORMAT1<newline>FORMAT2, FORMAT1 applies
to non-recent files and FORMAT2 to recent files; if STYLE is prefixed with ‘posix-’,
STYLE takes effect only outside the POSIX locale
The times on files are:
File: `sampledir/' Size: 4096 Blocks: 8 IO Block: 4096 directory Device: 900h/2304d Inode: 20447317 Links: 2 Access: (0755/drwxr-xr-x) Uid: ( 1123/ 23aaa) Gid: ( 1123/ 23aaa) Access: 2010-11-29 15:30:01.000000000 -0700 Modify: 2010-05-19 08:00:01.000000000 -0600 Change: 2010-05-19 08:00:01.000000000 -0600