Debian GNU/Linux : Guide to Installation and Usage by John Goerzen;Ossama Othman
page 76 of 298 (25%)
page 76 of 298 (25%)
![]() | ![]() |
|
There's a traditional, concise way of describing command syntax. Syntax
means the correct ways to combine various options and arguments. For example, if you type man man to get the manual page about man, you'll see several syntax descriptions beginning with the command name man. One of them will look like this: man -k [-M path] keyword ... Anything in brackets ([]) is an optional unit. In this case you don't have to use the -M option, but if you do, you must use a path argument. You must use the -k option and the keyword argument. The ... means that you could have more of whatever came before it, so you could look up several keywords. Let's look at one of the more complex descriptions from the man manual page: man [-c|-w|-tZT device] [-adhu7V] [-m system[,...]] [-L locale] [-p string] [-M path] [-P pager] [-r prompt] [-S list] [-e extension] [[section] page ...] ... There's no need to go through all of this (and don't worry about what it all means), but do pay attention to the organization of the description. First, clusters of options usually mean you can use one or more of them in different combinations, so -adhu7V means you can also use -h. However, you can't always use all combinations; this description doesn't make that clear. For example, -h is incompatible with other options, but you could |
|