2019-12-11 [Juming Chen] linux essays

1. pwd and cd and a switch command to determine the directory (see linux system management p43-p46)

(1) master pwd command functions: to determine the working directory is now located.

(2) master cd command functions: switch the current directory.

(3) master the "cd" command: Go to the parent directory.

(4) master the "cd" command: switch to the user's home directory.

(5) to master the "cd" command: the same cd ~. It can also be switched to the user's home directory.

(6) to master "cd-" command: before switching to the user working directory.

(7) to master the "cd directory name" command: switch to the specified directory.

2. Use is command to list the contents of a directory.

(1) control function is the command: list the current directory (default is the current directory) or specify the contents of the directory.

(2) master is-a command: list all files in the directory, including "-" hidden files that begin with

(A) for example: lists all files / home / dog directory, including hidden command file: is-a / home / dog

(3) for s-all command: the same is-a

(4) master is- / command: a directory lists the details of each file.

(a)is-//home/dog

3. Use the cp war makes copying files and directories (see linux system pipe p50)

(1) master the cp command functions: file (may be more) copied into a specified target directory.

(2) master the cp command common options

cp source file destination

(Cal-rcrecursive, recursive): recursively copy directory. When copying a directory, copy all the contents of the directory, which includes the entire contents of subdirectories.

(B) -f (force, mandatory): When the target file already exists without asking direct force replication.

4. Use the MV command to move and do not modify the file and directory names.

MV command master functions: not only can move files and directories between different directory, rename files and directories.

(2) master the MV command usage examples.

Examples of (a) move files and directories

The move lists files in the current directory to its subdirectory babydog commands: MV lists babydog

(B) Examples of renaming files and directories

The bigdog directory name to babydog command

Guess you like

Origin www.cnblogs.com/jumingchen/p/12025056.html