linux common commands (a) - ls

ls (List)

Description: display the directory file

Syntax: LS [ options ] [ file or directory ]

Command Options

-a show all files, including hidden files ( All )

 -A displays all files that contain hidden files, but does not contain. And ..

-l Detailed Information Display ( Long )

File Type Access count owner belongs to the group the file size (the default size is 1 last byte) modified filename

 

-d Do not expand the directory, display only the directory itself, generally -l used in conjunction to display the directory itself attribute information (only displays the contents of the current directory)

 -1 numeral 1 , a column display content

  -S sort to display the file size, from largest to smallest -r default after, from small to large

-U Sort stored sequentially displayed

     -X alphabetical sort of extension

     -t by mtime sort (most recent first display time)

     -ul by atime sort (most recent first display time)

     -ct by ctime sort (most recent first display time)

          supplement:

About time stamp:

          atime access time

          mtime data modification time (write, modify data mtime change, mtime change ctime will change)

          ctime metadata modification time (when only modify the permissions ctime change)

          It can be too "stat  file path " View All timestamps

 

 File type under Linux

In everything is file Linux at everything is a file , directory also includes one file and these files are classified into seven types:

• - : normal file  

• d:  directory file

• b:  block device

• c:  character device

• l:  symbolic link file  

• p:  pipe file pipe

• s:  socket file sock

Guess you like

Origin www.cnblogs.com/lin1874/p/12202471.html
Recommended