use %etcdir% for spacing instead of hardcoding
[mmh] / man / show.man
1 .\"
2 .\" %nmhwarning%
3 .\" $Id$
4 .\"
5 .TH SHOW %manext1% "%nmhdate%" MH.6.8 [%nmhversion%]
6 .SH NAME
7 show \- show (display) messages
8 .SH SYNOPSIS
9 .HP 5
10 .na
11 .B show
12 .RI [ +folder ]
13 .RI [ msgs ]
14 .RB [ \-draft ]
15 .RB [\-showproc
16 .IR program ]
17 .RB [ \-showmimeproc
18 .IR program ]
19 .RB [ \-header " | " \-noheader ]
20 .RB [ \-checkmime " | " \-nocheckmime ]
21 [switches\ for
22 .I showproc
23 or
24 .IR showmimeproc ]
25 .RB [ \-version ]
26 .RB [ \-help ]
27 .ad
28 .SH DESCRIPTION
29 .B Show
30 lists each of the specified messages to the standard output
31 (typically, the terminal).
32 .PP
33 By default, text (non-MIME) messages are filtered and displayed by
34 the
35 .B nmh
36 command
37 .BR mhl .
38 This command will display text
39 messages in a nice, uniform format.  It also allows you to configure
40 the format of the displayed messages and which headers fields are
41 shown.  See the
42 .BR mhl (1)
43 manual page for the details about this
44 command.  This default can be changed by defining the
45 .I showproc
46 profile component.  Any switches not recognized by
47 .B show
48 are
49 passed along to that program.  To override the default and the
50 .I showproc
51 profile component, use the
52 .B \-showproc
53 .I program
54 switch.  For example,
55 .B \-showproc
56 .I more
57 will cause the
58 .B more
59 program to list the messages with no reformatting.  Normally, this
60 program is specified as the
61 .I showproc
62 in the user's
63 .IR \&.mh\(ruprofile ,
64 rather than using a command line switch.
65 .PP
66 By default, non-text messages (MIME messages with multi-media
67 contents) are processed and displayed by the
68 .B nmh
69 command
70 .BR mhshow .
71 See the
72 .BR mhshow (1)
73 manual page for details
74 about this command.  This default can changed by defining the
75 .I showmimeproc
76 profile component.  Any switches not recognized
77 by
78 .B show
79 are passed along to that program.  To override this
80 default and the
81 .B showmimeproc
82 profile component, use the
83 .B \-showmimeproc
84 .I program
85 switch.
86 .PP
87 Note that in some cases,
88 .B show
89 may invoke the
90 .I showmimeproc
91 even for textual contents.  This will happen for text messages that
92 specify a transfer encoding (such as MIME quoted-printable or
93 base64) or specify a character set that
94 .B show
95 doesn't believe
96 can be displayed natively.  The environment variable
97 .B $MM_CHARSET
98 should be set to the terminal's native character set to avoid
99 gratuitous invocations of the
100 .IR showmimeproc .
101 See the
102 .BR mh-profile (5)
103 man page for details about this environment variable.
104 .PP
105 The option
106 .B \-checkmime
107 (set by default) instructs
108 .B show
109 to
110 test if any of the messages to be displayed are non-text (MIME)
111 messages.  If any are non-text, they are displayed by the program
112 .IR showmimeproc ,
113 else they are displayed by the program
114 .IR showproc .
115 The option
116 .B \-nocheckmime
117 disables this test and instructs
118 .B show
119 to use
120 .IR showproc ,
121 regardless of whether
122 any of the messages are non-text (MIME) messages.
123 .P
124 The
125 .B \-noshowproc
126 switch will disable any formatting or paging of
127 messages.  It is equivalent to
128 .B \-nocheckmime
129 .B \-showproc
130 .IR cat .
131 It is still accepted, but should be considered (somewhat) obsolete.
132 .PP
133 If the environment variable
134 .B $NOMHNPROC
135 is set, the test for
136 non-text (MIME) messages will be disabled.  This method is obsolete.
137 Use the
138 .B \-nocheckmime
139 switch instead.
140 .PP
141 The
142 .B \-header
143 switch tells
144 .B show
145 to display a one\-line
146 description of the message being shown.  This description includes
147 the folder and the message number.
148 .PP
149 If no `msgs' are specified, the current message is used.  Although
150 it depends on the specific
151 .I showproc
152 or
153 .IR showmimeproc ,
154 in the default setup when more than one message is specified, you
155 will be prompted for a <RETURN> prior to listing each message.
156 Each message will be listed a page at a time, and when the end of
157 page is reached, the program will wait for a <SPACE> or <RETURN>.
158 If a <RETURN> is entered, it will print the next line, whereas
159 <SPACE> will print the next screenful.
160 .PP
161 If the standard output is not a terminal, no queries are made, and
162 each file is listed with a one\-line header and two lines of
163 separation.
164 .PP
165 .RB \*(lq "show \-draft" \*(rq
166 will list the file <mh\-dir>/draft if it
167 exists.
168 .PP
169 If the profile entry \*(lqUnseen\-Sequence\*(rq is present and
170 non\-empty, then
171 .B show
172 will remove each of the messages shown
173 from each sequence named by the profile entry.
174
175 .SH FILES
176 .fc ^ ~
177 .nf
178 .ta \w'%etcdir%/ExtraBigFileName  'u
179 ^$HOME/\&.mh\(ruprofile~^The user profile
180 .fi
181
182 .SH "PROFILE COMPONENTS"
183 .fc ^ ~
184 .nf
185 .ta 2.4i
186 .ta \w'ExtraBigProfileName  'u
187 ^Path:~^To determine the user's nmh directory
188 ^Current\-Folder:~^To find the default current folder
189 ^Unseen\-Sequence:~^To name sequences denoting unseen messages
190 ^showproc:~^Program to show text (non-MIME) messages
191 ^showmimeproc:~^Program to show non-text (MIME) messages
192 .fi
193
194 .SH "SEE ALSO"
195 mhl(1), mhshow(1), more(1), next(1), prev(1), scan(1)
196
197 .SH DEFAULTS
198 .nf
199 .RB ` +folder "' defaults to the current folder"
200 .RB ` msgs "' defaults to cur"
201 .RB ` \-checkmime '
202 .RB ` \-header '
203 .fi
204
205 .SH CONTEXT
206 If a folder is given, it will become the current folder.  The last
207 message shown will become the current message.
208
209 .SH BUGS
210 The
211 .B \-header
212 switch doesn't work when `msgs' expands to more than
213 one message.  If the
214 .I showproc
215 is
216 .BR mhl ,
217 then this problem can
218 be circumvented by referencing the \*(lqmessagename\*(rq field in the
219 .B mhl
220 format file.
221 .PP
222 .B Show
223 updates the user's context before showing the message.
224 Hence
225 .B show
226 will mark messages as seen prior to the user actually
227 seeing them.  This is generally not a problem, unless the user relies
228 on the \*(lqunseen\*(rq messages mechanism, and interrupts
229 .B show
230 while it is showing \*(lqunseen\*(rq messages.
231 .PP
232 If your
233 .I showproc
234 is
235 .B mhl
236 (the default), then
237 .B show
238 uses
239 a built\-in
240 .BR mhl :
241 it does not actually run the
242 .B mhl
243 program.
244 Hence, if you define your own
245 .B showproc ,
246 don't call it
247 .B mhl
248 since
249 .B show
250 won't run it.
251 .PP
252 If your
253 .I showproc
254 is the pager
255 .BR more ,
256 then avoid running
257 .B show
258 in the background with only its standard output piped to
259 another process, as in
260 .PP
261 .RS 5
262 show | imprint &
263 .RE
264 .PP
265 Due to a bug in
266 .BR more ,
267 show will go into a \*(lqtty input\*(rq state.
268 To avoid this problem, re\-direct
269 .BR show 's
270 diagnostic output as well.
271 For users of
272 .BR csh :
273 .PP
274 .RS 5
275 show |& imprint &
276 .RE
277 .PP
278 For users of
279 .BR sh :
280 .PP
281 .RS 5
282 show 2>&1 | imprint &
283 .RE