table of Contents
Video tutorial lesson but learning Mu: https://www.imooc.com/video/4306
This section summarizes the study and made notes.
Help command in Linux
Help command: man
grammar:
man 命令
获取指定命令的帮助。如[man ls]查看ls命令的帮助。
man's level:
-
1: View command help
-
2: View function can be called to help the kernel
-
3: View help functions and libraries
-
4: View the help of a special file (mainly the files in the / dev directory)
-
5: View the profile help
-
6: View game help
-
7: View help other miscellaneous items
-
Help system administrators to view the available commands: 8
-
9: Help Viewer and kernel-related documents
View command has that level of help:
man -f命令
相当于
whatis命令
例如:[man -5 passwd]、[man -4 null]、[man -8 ifconfig]等
See all the help and commands related to:
man -k命令
相当于
apropos命令
例如apropos passwd
Example 1: man ls command to view the help ls command.
Example 2: man -f ls command to view the ls command has what level of help
Example 3: apropos passwd command , all commands and passwd command to view the relevant help.
Options Help command
选项帮助:
命令 --help
获取指定命令选项的帮助,如[ls --help]。
Example 1: ls --help command to see options to help the ls command, ls command to see what options there are.
Internal Shell Command Help
Shell内部命令帮助:
help shell内部命令
获取shell内部命令的帮助,如[whereis cd]确定是否是shell内部命令;如[help cd]获取内部命令帮助。
Example 1: help cd command , see the help cd command.
Detailed command help: info
详细命令帮助info:
info 命令
- 回车:进入子帮助页面(带有*号标记)
- u:进入上层页面
- n:进入下一个帮助小节
- p:进入上一个帮助小节
- q:推出
Example 1: info ls command to view the document ls command.