linux 基础(常用)命令

1.一般命令格式

Linux命令通常由以下三部分组成:
command [-option] [argument]
command:即是要运行命令的本身,像我们调用的函数。
option     :的话是可选的,即有些命令是没有选项的,选项(也有人称之为参数,因为从编程的角度来说,它就是参数),选项是控制命令运行状态和行为的
argument:是参数,是命令要操作的文件、路径、数据等,也是可选的,因为有些命令不需要操作这些内容。

2.常用的命令

pwd, cd, ls, cat,cp, mv, rm, head, tail, find, man等命令的使用方法

pwd

Print Working Directory

打印出当前工作路径

linux 基础(常用)命令


cd

Change Directory - change the current working directory to a specific Folder

切换工作目录

linux 基础(常用)命令


ls

 List directory contents

linux 基础(常用)命令


cat

Concatenate and print (display) the content of files

linux 基础(常用)命令


cp

Copy files and directories

linux 基础(常用)命令


mv

 Move or rename files or directories.

linux 基础(常用)命令


rm

Remove files or directories

linux 基础(常用)命令


head

Output the first part of files, prints the first part (10 lines by default) of each file.

 linux 基础(常用)命令


tail

 Output the last part of files, print the last part (10 lines by default) of each FILE.

linux 基础(常用)命令


find

Search for files in a directory hierarchy.

linux 基础(常用)命令


man

 man是一个获取某个命令使用方法的工具。

linux 基础(常用)命令