1 NMH MANPAGE STYLE GUIDE
3 nmh manpages should be in this general form and section order:
5 .TH COMP %manext1% "DATE" "%nmhversion%"
10 comp \- compose a message
20 .RB [ \-use " | " \-nouse ]
26 is used to create a new message to be mailed. It copies something.
28 .SH "PROFILE COMPONENTS"
31 Location of the user's MH folder directory
34 The pager command name
39 defaults to the current folder
47 description of filename1
50 description of filename2
59 .\" Leave out the BUGS section if there are none worth describing.
63 ---------------------------------------
64 The DATE in the .TH macro should reflect the most recent non-trivial
65 update to the content of the manpage; formatting changes don't count.
66 Spell out the date (no abbreviations or shortcuts):
74 Don't abbreviate the month.
77 In the FILES section, prefer the default .TP indent. The pathnames are
78 variable and long, so any indentation value that works for you won't
79 work for someone using a different directory layout.
84 There should be no ".so" commands to source an external file,
85 since these break on Linux, where the man program does not
86 allow source files outside the man/ hierarchy. Instead, insert
97 Of course, replace "components" with a unique identifier that
98 reflects the content being included, like "mts_conf" for
99 etc/mts.conf. Then, add two lines to the man.sed target in
102 echo '/%components%/r $(top_srcdir)/etc/components' >> $@
103 echo ' s,%components%,,g' >> $@
105 At compile time, the contents of the file will physically
106 incorporated into the body of the man page. This is somewhat
107 unfortunate, since later modifications won't be reflected in
108 the manpage, but on the other hand, the manpage will show the
109 default configuration and not local modifications.
113 All nmh program names should be bolded. If there is punctuation
114 after the name, use a .BR construct to avoid the automatic
115 space that's inserted with just a .B:
120 If this is a manpage reference, use:
126 Literal text (such as flags) should be in bold. Parameters
127 should be italicized. Mutually exclusive options (like
128 "-foo" and "-nofoo") should be grouped together and seperated
131 .RI [ +folder ] <---- parameter
132 .RI [ msgs ] <---- parameter
133 .RB [ \-version ] <---- flag
134 .RB [ \-editor <---- flag with
135 .IR editor ] parameter
136 .RB [ \-use " | " \-nouse ] <---- exclusive parameters
138 References to these flags or parameters in the body text of the
139 manpage should reflect these conventions:
141 You may not supply both a
150 In particular, don't enclose them in single quotes (except
151 in the DEFAULT section, which might be inconsistent, but
152 seems a little clearer.
154 For "-flag param" situations, try to use a .B/.I combination
155 instead of a single .BI, since it allows more flexibility in
156 case of punctuation, and we get an automatic space between
157 flag and param for free, without having to manual force it.
161 Use ".SS" to denote a subsection
165 The folder manpage has an example of a table.
170 .ta \w'/rnd/phyl/Mail/EP 'u +\w'has ddd messages 'u +\w'(ddd\-ddd); 'u
171 FOLDER \0\0\0\0\0\0# MESSAGES RANGE CUR (OTHERS)
172 ff has \0no messages.
173 inbox+ has \016 messages (\03\-\022); cur=\05.
174 mh has \076 messages (15\-\076); cur=70.
179 Other italicized text
181 Italicize file names, profile entries, and folder names:
184 .RI \*(lq components \*(rq
185 exists in the user's nmh directory,
187 If the user's profile contains a
188 .RI \*(lq "Msg\-Protect: nnn" \*(rq
191 The \*(lq+\*(rq after
193 indicates that it is the current folder.
195 Enclose the file names and profile entries in lq/rq
200 Certain manpages are shared between one or more programs
201 (such as folder/folders). The secondary program should
202 have a man page that only contains:
206 Also, add this manpage to the appropriate section in Makefile.in
210 Don't include a CONTEXT section when contexts are not
214 AUTHOR and HISTORY sections
216 These have no place in a manpage. If you want everlasting glory,
217 try the release notes.
221 The BUGS section goes last.