linux下的查看帮助命令:whatis,man

来源:互联网 发布:睡衣 知乎 编辑:程序博客网 时间:2024/05/23 14:48

俗话说:Linux一切皆文件,对Linux的操作也主要是通过命令来完成的,这不同与Windows操作系统,点击几下就好了,这也就意味着有更多的命令需要去学习和记忆,当然这么多命令要记得很清楚是不可能的,所以Linux提供了一些用于查看帮助的命令,下面就简单介绍一下吧。

(1)whatis:用于查询一个命令执行什么功能,并将查询结果打印到终端上。

例:

[root@localhost ~]# whatis ls 

(1) - list directory contents ls

 (1p) - list directory contents 

[root@localhost ~]# whatis cp cp 

(1) - copy files and directories cp

 (1p) - copy files 

[root@localhost ~]# whatis chown chown

 (1) - change file owner and group chown

 (1p) - change the file ownership chown

 (2) - change ownership of a file chown 

(3p) - change owner and group of a file 



(2)man:Linux提供了丰富的帮助手册,当你需要查看某个命令的参数时不必到处上网查找,只要man一下即可。

比如我执行 man pwd 命令,显示如下:



后面还有的话再继续添加吧。欢迎大家补充。

1 0