Linux operating system Operation Command

1. who view the current system login user

2. pwd print out the working path

3. ls lists the current directory of text 

     ls  [option]

    -a: Displays all subdirectories and files in the top directory, including hidden files

    -A: show all subdirectories and files in the specified directory, including hidden files, no single list and "..". "."

    -d: If the argument is a directory, only its name is displayed under each file without displaying it, and often used in conjunction with an option to obtain detailed information directories.

    -l: long format to display the details of the file.

    -L: If the specified file name is a symbolic link, the file link points to display.

    -m: output in the character stream format, the file is displayed across the page, separated by commas.

    -n: -l same as the output format

    -R: recursively displaying files in subdirectories in the specified directory.

 4. cd directory switching operation

 cd [directory]

5. mkidr create the directory.

    mkdir [option] [dirname]

    -m: permission settings are stored on the new directory

    -p: can be a path name

6. rmdir remove directory.

7. touch if the file does not exist, create the back, there are flowers to change the file timestamp information

8. cat View files tac 

    cat  [option]  filename

9. cp copy files.

    cp  [option]  [src-file|src-dir]  [dst-file|dst-dir]

    -a: change option is usually used when copying a directory, it retains links, file attributes, and recursively copy directory

    -d: copy retained links

    -f: Delete the existing catalog file without prompting

    -r: If the source file is given a directory file, then cp will copy recursively all the subdirectories and files in the directory. At this time, the target file is a directory name compulsory.

    -l: not just copy the linked files

10. mv move files, rename files

    mv [option]   [src-file|src-dir]  [dst-file|dst-dir]

11. rm remove files or directories

    rm [option] [file|dirs]

12. more less pagination

    more  [option] fileename

    -p: display screen is cleared before the next screen

    -c: similar role with -p

    -d: displayed at the bottom of each screen friendly message to "--more - (XX)%"

    -s: file compressed into a contiguous blank blank lines.

 

Guess you like

Origin www.cnblogs.com/daibiao/p/11794226.html