Create command
1. Create a Directory
mkdir (make directory) directory name example: mkdir 123
mkdir Directory name 1/directory Name 2 example: mkdir 123/456 (1 and 2 directories adjacent)
2. Create a document
Gedit Document name Example: Gedit 1.c
3. Create a shortcut
Ln-s Linked-file Link-name
Open command (CD)
1. Open subdirectories of the current directory
CD Name-of-directory
2. Open the parent directory of the current directory
Cd..
3. Open the Home directory
Cd
4. Open a user's home directory
CD ~bill
Copy command
1. Copying files in the current directory
CP Sourse-file Dest-file
2. Copy multiple files to the directory
CP file1 File2 Directory
3. Copy all items in the directory
Cp-r Source-dir Dest-dir
Rsync-a source-dir/dest-dir/
Delete command
1. delete files or shortcuts
RM file1 Link1
2. Delete Empty directory
RmDir dir
3. Delete a non-empty directory
Rm-rf dir
Print command
1. Print the current directory address
Pwd
2. Print all files (not starting with.)
Ls
3. List all information
Ls-l
4. List all files (including starting with.)
Ls-a
5. Chronological order
Ls-t
6. By size
Ls-s
7. Reverse Order
Ls-r
8. The more new The more backward
Ls-ltr
9. List the bugs in the name
LS *bug*
10. List the end of the.
LS *.?
Connection command (directly displayed in the command interface)
1. Connection files
Cat File1 File2
2. Connection files But delimited
More File1 File2
3. Connect all
Cat *
4. Connect all hidden files (start with.)
Cat. *
4. Connect all with log as suffix
Cat *.log
Rename command
MV Source-file Dest-file
A Linux command can execute multiple commands on a single line, such as Ls-a-l equivalent to performing ls-a+ls-l
command of Linux (1)