Unix 简明教程
Unix / Linux - Shell Manpage Help
所有 Unix 命令都带有一些可选项和必选项。忘记这些命令的完整语法很常见。
All the Unix commands come with a number of optional and mandatory options. It is very common to forget the complete syntax of these commands.
因为没有人可能记住每一个 Unix 命令和它的所有选项,因此,我们拥有在线帮助来缓解这一点,并且这种在线帮助 منذ أن كان Unix 处于开发阶段起就可用了。
Because no one can possibly remember every Unix command and all its options, we have online help available to mitigate this right from when Unix was at its development stage.
Unix 的下载版本 Help files 称为 man pages 。如果有一个命令名称,你不确定如何使用它,那么手册页可以帮你解决每一步。
Unix’s version of Help files are called man pages. If there is a command name and you are not sure how to use it, then Man Pages help you out with every step.
Syntax
这是一个简单的命令,它可以帮助你获取任何 Unix 命令的详细信息,同时与系统一起使用:
Here is the simple command that helps you get the detail of any Unix command while working with the system −
$man command
Example
假设有一条命令要求您获得帮助;假设您想要了解 pwd ,那么您只需使用以下命令:
Suppose there is a command that requires you to get help; assume that you want to know about pwd then you simply need to use the following command −
$man pwd
上述命令可帮助您获得 pwd 命令的完整信息。在您的命令提示符处自己尝试一下以获取更多详细信息。
The above command helps you with the complete information about the pwd command. Try it yourself at your command prompt to get more detail.
您可以使用以下命令来获取 man 命令本身的完整信息:
You can get complete detail on man command itself using the following command −
$man man
Man Page Sections
手册页通常分为几节,一般根据手册页作者的偏好而有所不同。下表列出了一些常见部分:
Man pages are generally divided into sections, which generally vary by the man page author’s preference. Following table lists some common sections −
Sr.No. |
Section & Description |
1 |
NAME Name of the command |
2 |
SYNOPSIS General usage parameters of the command |
3 |
DESCRIPTION Describes what the command does |
4 |
OPTIONS Describes all the arguments or options to the command |
5 |
SEE ALSO Lists other commands that are directly related to the command in the man page or closely resemble its functionality |
6 |
BUGS Explains any known issues or bugs that exist with the command or its output |
7 |
EXAMPLES Common usage examples that give the reader an idea of how the command can be used |
8 |
AUTHORS The author of the man page/command |
总而言之,手册页是一项至关重要的资源,当您需要有关 Unix 系统中的命令或文件的信息时,它是一种首要的研究途径。
To sum it up, man pages are a vital resource and the first avenue of research when you need information about commands or files in a Unix system.
Useful Shell Commands
以下链接为您提供了最重要的和最常用的 Unix Shell 命令列表。
The following link gives you a list of the most important and very frequently used Unix Shell commands.
如果您不知道如何使用任何命令,请使用手册页来了解有关该命令的完整详细信息。
If you do not know how to use any command, then use man page to get complete detail about the command.
以下是 Unix Shell - Useful Commands 的列表:
Here is the list of Unix Shell - Useful Commands