home *** CD-ROM | disk | FTP | other *** search
-
- ; doc2man
- ; Fri Feb 03 23:50:02 1995
-
- doc2man(8) - maint utils
-
- NAME:
-
- doc2man - convert ascii doc file (formatted) to man page format (37.9, Feb/95)
-
- SYNOPSIS:
-
- doc2man <infile >outfile
-
- (uses stdio so i/o redirection will be desired)
-
- DESCRIPTION:
-
- {doc2man} will convert a specially-formatted text file into a manual page
- file, formattable by the {man} program. See one of the sample mandocs for
- a good example of the file format.
-
- First line must be of the form:
-
- filename(n) - optional text here
-
- where _filename_ is the output name of the man page, and _n_ is a section number
- corresponding with the following (modeled after the Unix convention):
-
- 1 = User Commands
- 2 = System Kernel Functions
- 3 = C Library Functions
- 4 = Device Interfaces
- 5 = File Formats
- 6 = Games and Demos
- 7 = Environments and Tables
- 8 = Maintenance Commands
-
- Following that and a blank line will come the rest of the file, broken into
- subsections. Each subsection will start with its own header, isolated on
- a line all in uppercase characters and terminated with a colon.
-
- doc2man will recognize some particularly common section types, whose names will
- be represented in the man file with an encoded identifier to save space. Any
- unrecognized ones will have their text represented verbatim. Recognized are:
- NAME, SYNOPSIS, DESCRIPTION, EXAMPLE, PORTABILITY, SEE ALSO, FILES,
- BUGS, NOTES, OPTIONS, RETURNS, AUTHOR, LICENCE
-
- Note that often variations will also be recognized, e.g. plurals and such.
- When {man} formats the output, the subsection headers will be displayed flush
- left and in bold type.
-
- The body of the section, which follows, will be displayed justified. However,
- paragraphs may be broken as frequently as desired for visual clarity in the
- ascii file -- doc2man will automatically strip the linefeeds. Multiple
- paragraphs should be separated by a blank line -- this will be recognized and
- formatting will be done accordingly. There is no limit to the number of
- paragraphs per subsection; sections are assumed to end when a line meeting
- the criteria for a header above is encountered.
-
- Special formatting codes may be embedded within the file for character type
- variety. Following are a line of set type, and its formatted counterpart:
-
- _To get_: Plain, {italicized}, |bolded|, _underlined_
-
- _Type_: Plain, \{italicized\}, \|bolded\|, \_underlined\_
-
- Note, however, that to use one of the above formatting characters literally
- it must be escaped with a backslash (as must a backslash itself):
-
- _To get_: You will notice the \_symbols\\ \|\|\| in this text\}.
-
- _Type_: You will notice the \\\_symbols\\\\ \\\|\\\|\\\| in this text\\\}.
-
- The file may simply end after the last section's text.
-
- OPTIONS:
-
- None at present.
-
- SEE ALSO:
-
- {man2doc}, {guide2man}, {man}
-
-