0f05b68fb2a966d9d9b647cfbd4121ed2a1ac0e8
[mmh] / man / forw.man
1 .\"
2 .\" %nmhwarning%
3 .\" $Id$
4 .\"
5 .TH FORW %manext1% "%nmhdate%" MH.6.8 [%nmhversion%]
6 .SH NAME
7 forw \- forward messages
8 .SH SYNOPSIS
9 .HP 5
10 .na
11 .B forw
12 .RI [ +folder ]
13 .RI [ msgs ]
14 .RB [ \-annotate " | " \-noannotate ] 
15 .RB [ \-form
16 .IR formfile ]
17 .RB [ \-format " | " \-noformat ]
18 .RB [ \-filter
19 .IR filterfile ]
20 .RB [ \-inplace " | " \-noinplace ]
21 .RB [ \-mime " | " \-nomime ]
22 .RB [ \-draftfolder
23 .IR +folder ]
24 .RB [ \-draftmessage
25 .IR msg ]
26 .RB [ \-nodraftfolder ]
27 .RB [ \-editor
28 .IR editor ]
29 .RB [ \-noedit ]
30 .RB [ \-whatnowproc
31 .IR program ]
32 .RB [ \-nowhatnowproc ]
33 .RB [ \-dashstuffing " | " \-nodashstuffing ]
34 .RB [ \-build ]
35 .RB [ \-file
36 .IR msgfile ]
37 .RB [ \-version ]
38 .RB [ \-help ]
39 .PP
40 .HP 5
41 .B forw
42 .RI [ +folder ]
43 .RI [ msgs ]
44 .RB [ \-digest
45 .IR list ]
46 .RB [ \-issue
47 .IR number ]
48 .RB [ \-volume
49 .IR number ]
50 [other\ switches\ for\ 
51 .BR forw ]
52 .RB [ \-version ]
53 .RB [ \-help ]
54 .ad
55 .SH DESCRIPTION
56 .B Forw
57 may be used to prepare a message containing other messages.
58 .PP
59 It constructs the new message from a forms (components) file, with a
60 body composed of the message(s) to be forwarded.  An editor is invoked
61 as in
62 .BR comp ,
63 and after editing is complete, the user is prompted
64 before the message is sent.
65 .PP
66 The default message form contains the following elements:
67 .PP
68 .RS 5
69 .nf
70 %forwcomps%
71 .fi
72 .RE
73 .PP
74 If a file named
75 .RI \*(lq forwcomps \*(rq
76 exists in the user's nmh directory,
77 it will be used instead of this default form.  You may also specify an
78 alternate forms file with the switch
79 .B \-form
80 .IR formfile .
81 .PP
82 If the draft already exists,
83 .B forw
84 will ask you as to the disposition
85 of the draft.  A reply of
86 .B quit
87 will abort
88 .BR forw ,
89 leaving the draft intact;
90 .B replace
91 will replace the existing draft with a blank skeleton; and
92 .B list
93 will display the draft.
94 .PP
95 If the
96 .B \-annotate
97 switch is given, each message being forwarded will
98 be annotated with the lines:
99 .PP
100 .RS 5
101 .nf
102 Forwarded:\ date
103 Forwarded:\ addrs
104 .fi
105 .RE
106 .PP
107 where each address list contains as many lines as required.  This
108 annotation will be done only if the message is sent directly from
109 .BR forw .
110 If the message is not sent immediately from
111 .BR forw ,
112 .RB \*(lq comp
113 .BR \-use \*(rq
114 may be used to re\-edit and send the constructed
115 message, but the annotations won't take place.  Normally annotations
116 are done inplace in order to preserve any links to the message.  You may
117 change this by using the
118 .B \-noinplace
119 switch.
120 .PP
121 See
122 .BR comp (1)
123 for a description of the
124 .B \-editor
125 and
126 .B \-noedit
127 switches.
128 .PP
129 Although
130 .B forw
131 uses a forms (components) file to direct it how to
132 construct the beginning of the draft, it uses a message filter file to
133 direct it as to how each forwarded message should be formatted in the
134 body of the draft.  The filter file for \fIforw\fR should be a standard
135 form file for
136 .BR mhl ,
137 as
138 .B forw
139 will invoke
140 .B mhl
141 to filter (re\-format) the forwarded messages prior to being output to
142 the body of the draft.
143 .PP
144 The switches
145 .BR \-noformat ,
146 .BR \-format ,
147 and
148 .B \-filter
149 .I filterfile
150 specify which message filter file to use.
151 .PP
152 If
153 .B \-noformat
154 is specified (this is the default), then each forwarded
155 message is output into the draft exactly as it appears with no
156 .B mhl
157 filtering.
158 .PP
159 If
160 .B \-format
161 is specified, then a default message filter file is used.
162 This default message filter should be adequate for most users.
163 This default filter
164 .RI \*(lq mhl.forward \*(rq
165 is:
166 .PP
167 .RS 5
168 .nf
169 %mhl_forward%
170 .fi
171 .RE
172 .PP
173 If a file named
174 .RI \*(lq mhl.forward \*(rq
175 exists in the user's nmh
176 directory, it will be used instead of this form.  You may specify an
177 alternate message filter file with the switch
178 .B \-filter
179 .IR filterfile .
180 .PP
181 Each forwarded message is separated with an encapsulation delimiter.
182 By default, any dashes in the first column of the forwarded messages
183 will be prepended with `\-\ ' so that when received, the message is
184 suitable for bursting by
185 .BR burst .
186 This follows the Internet RFC\-934 guidelines.  You may use the flag
187 .B \-nodashstuffing
188 in order
189 to suppress this form of quoting to the forwarded messages.
190 .PP
191 For users of
192 .BR prompter ,
193 by specifying
194 .BR prompter 's
195 .B \-prepend
196 switch in the
197 .I \&.mh\(ruprofile
198 file, any commentary text is entered
199 before the forwarded messages.  (A major win!)
200 .PP
201 To use the MIME rules for encapsulation, specify the
202 .B \-mime
203 switch. This directs
204 .B forw
205 to generate an
206 .B mhbuild
207 composition file. Note that
208 .B nmh
209 will not invoke
210 .B mhbuild
211 automatically, unless you
212 add this line to your
213 .I \&.mh\(ruprofile
214 file:
215 .PP
216 .RS 5
217 .nf
218 automimeproc: 1
219 .fi
220 .RE
221 .PP
222 Otherwise, you must specifically give the command
223 .PP
224 .RS 5
225 .nf
226 What now? mime
227 .fi
228 .RE
229 .PP
230 prior to sending the draft.
231 .PP
232 The
233 .B \-draftfolder
234 .I +folder
235 and
236 .B \-draftmessage
237 .I msg
238 switches invoke the
239 .B nmh
240 draft folder facility.  This is an advanced (and highly
241 useful) feature.  Consult the
242 .BR mh-draft (5)
243 man page for more information.
244 .PP
245 The
246 .B \-editor
247 .I editor
248 switch indicates the editor to use for the
249 initial edit.  Upon exiting from the editor,
250 .B comp
251 will invoke the
252 .B whatnow
253 program.  See
254 .BR whatnow (1)
255 for a discussion of
256 available options.  The invocation of this program can be inhibited
257 by using the
258 .B \-nowhatnowproc
259 switch.  (In truth of fact, it is
260 the
261 .I whatnow
262 program which starts the initial edit.  Hence,
263 .B \-nowhatnowproc
264 will prevent any edit from occurring.)
265 .PP
266 The
267 .B \-build
268 switch is intended to be used by the Emacs mh-e interface to
269 .BR nmh ,
270 and is only present if
271 .B nmh
272 was compiled with support for mh-e. It implies
273 .BR \-nowhatnowproc .
274 It causes a file <mh\-dir>/draft
275 to be created, containing the draft message that would normally be presented
276 to the user for editing.
277 No mail is actually sent. Note that this switch is not guaranteed to
278 be present or to have the same effects in future versions of
279 .BR nmh :
280 it is documented here only for completeness.
281 .PP
282 The
283 .B \-file
284 .I msgfile
285 switch specifies the message to be forwarded as an 
286 exact filename rather than as an
287 .B nmh
288 folder and message number. It is 
289 intended to be used by the
290 .B msh
291 interface to
292 .BR nmh . 
293 This switch implies
294 .BR \-noannotate .
295 The forwarded message is simply
296 copied verbatim into the draft; the processing implied by
297 the
298 .BR \-filter ,
299 .BR \-mime ,
300 and
301 .B \-digest
302 switches is bypassed, and the usual leading and
303 trailing 'Forwarded Message' delimiters are not added.
304 The same caveats apply to this option as to the
305 .B \-build
306 switch.
307 .PP
308 The
309 .B \-digest
310 .IR list ,
311 .B \-issue
312 .IR number ,
313 and
314 .B \-volume
315 .I number
316 switches implement a digest facility for
317 .BR nmh .
318 Specifying these switches enables and/or overloads the following escapes:
319 .PP
320 .RS 5
321 .nf
322 .ta \w'Component  'u +\w'Escape  'u +\w'Returns  'u
323 .I Type Escape  Returns Description
324 component       digest  string  Argument to `\-digest'
325 function        cur     integer Argument to `\-volume'
326 function        msg     integer Argument to `\-issue'
327 .fi
328 .RE
329 .PP
330 Consult the
331 .I "Advanced Features"
332 section of the
333 .B nmh
334 User's Manual for more information on making digests.
335
336 .SH FILES
337 .fc ^ ~
338 .nf
339 .ta \w'%etcdir%/ExtraBigFileName  'u
340 ^%etcdir%/forwcomps~^The standard message skeleton
341 ^or <mh\-dir>/forwcomps~^Rather than the standard skeleton
342 ^%etcdir%/digestcomps~^The message skeleton if `\-digest' is given
343 ^or <mh\-dir>/digestcomps~^Rather than the standard skeleton
344 ^%etcdir%/mhl.forward~^The standard message filter
345 ^or <mh\-dir>/mhl.forward~^Rather than the standard filter
346 ^$HOME/\&.mh\(ruprofile~^The user profile
347 ^<mh\-dir>/draft~^The draft file
348 .fi
349
350 .SH "PROFILE COMPONENTS"
351 .fc ^ ~
352 .nf
353 .ta 2.4i
354 .ta \w'ExtraBigProfileName  'u
355 ^Path:~^To determine the user's nmh directory
356 ^Current\-Folder:~^To find the default current folder
357 ^Draft\-Folder:~^To find the default draft\-folder
358 ^Editor:~^To override the default editor
359 ^Msg\-Protect:~^To set mode when creating a new message (draft)
360 ^fileproc:~^Program to refile the message
361 ^mhlproc:~^Program to filter messages being forwarded
362 ^whatnowproc:~^Program to ask the \*(lqWhat now?\*(rq questions
363 .fi
364
365 .SH "SEE ALSO"
366 mhbuild(1), comp(1), repl(1), send(1), whatnow(1), mh\-format(5),
367 .I "Proposed Standard for Message Encapsulation"
368 (RFC\-934)
369
370 .SH DEFAULTS
371 .nf
372 .RB ` +folder "' defaults to the current folder"
373 .RB ` msgs "' defaults to cur"
374 .RB ` \-noannotate '
375 .RB ` \-nodraftfolder '
376 .RB ` \-noformat '
377 .RB ` \-inplace '
378 .RB ` \-dashstuffing '
379 .RB ` \-nomime '
380 .fi
381
382 .SH CONTEXT
383 If a folder is given, it will become the current folder.
384 The first message forwarded will become the current message.
385
386 .SH BUGS
387 If
388 .I whatnowproc
389 is
390 .BR whatnow ,
391 then
392 .B forw
393 uses a built\-in
394 .BR whatnow ,
395 it does not actually run the
396 .B whatnow
397 program.
398 Hence, if you define your own
399 .IR whatnowproc ,
400 don't call it
401 .B whatnow
402 since
403 .B forw
404 won't run it.
405 .PP
406 When
407 .B forw
408 is told to annotate the messages it forwards, it
409 doesn't actually annotate them until the draft is successfully sent.
410 If from the
411 .IR whatnowproc ,
412 you
413 .B push
414 instead of
415 .BR send ,
416 it's possible to confuse
417 .B forw
418 by re\-ordering the file (e.g. by using
419 .RB \*(lq folder
420 .BR \-pack \*(rq)
421 before the message is successfully sent.
422 .B Dist
423 and
424 .B repl
425 don't have this problem.