2e65aafb52b8d6d479de5ab2d5848e42922df773
[mmh] / man / dist.man
1 .\"
2 .\" %nmhwarning%
3 .\" $Id$
4 .\"
5 .TH DIST %manext1% "%nmhdate%" MH.6.8 [%nmhversion%]
6 .SH NAME
7 dist \- redistribute a message to additional addresses
8 .SH SYNOPSIS
9 .HP 5
10 .B dist
11 .RI [ +folder ]
12 .RI [ msgs ]
13 .RB [ \-form
14 .IR formfile ]
15 .RB [ \-annotate " | " \-noannotate ] 
16 .RB [ \-inplace " | " \-noinplace ] 
17 .RB [ \-draftfolder
18 .IR +folder ]
19 .RB [ \-draftmessage
20 .IR msg ]
21 .RB [ \-nodraftfolder ]
22 .RB [ \-editor
23 .IR editor ]
24 .RB [ \-noedit ]
25 .RB [ \-whatnowproc
26 .IR program ]
27 .RB [ \-nowhatnowproc ]
28 .RB [ \-version ]
29 .RB [ \-help ]
30 .SH DESCRIPTION
31 .B Dist
32 is similar to
33 .BR forw .
34 It prepares the specified message
35 for redistribution to addresses that (presumably) are not on the original
36 address list.
37 .PP
38 The default message form contains the following elements:
39 .PP
40 .RS 5
41 .nf
42 %distcomps%
43 .fi
44 .RE
45 .PP
46 If a file named
47 .RI \*(lq distcomps \*(rq
48 exists in the user's nmh directory, it
49 will be used instead of this default form.  You may specify an alternate
50 forms file with the switch
51 .B \-form
52 .IR formfile .
53 The form used will be prepended to the message being resent.
54 .PP
55 If the draft already exists,
56 .B dist
57 will ask you as to the disposition of the draft.  A reply of
58 .B quit
59 will abort
60 .BR dist ,
61 leaving the draft intact;
62 .B replace
63 will replace the existing draft with a blank skeleton; and
64 .B list
65 will display the draft.
66 .PP
67 Only those addresses in
68 .RI \*(lq Resent\-To: \*(rq,
69 .RI \*(lq Resent\-cc: \*(rq,
70 and
71 .RI \*(lq Resent\-Bcc: \*(rq
72 will be sent.  Also, a
73 .RI \*(lq "Resent\-Fcc: folder" \*(rq
74 will be honored (see
75 .BR send (1)).
76 Note that with
77 .BR dist ,
78 the draft should contain only
79 .RI \*(lq Resent\-xxx: \*(rq
80 fields and no body.  The headers and the body of
81 the original message are copied to the draft when the message is sent.
82 Use care in constructing the headers for the redistribution.
83 .PP
84 If the
85 .B \-annotate
86 switch is given, the  message being distributed will
87 be annotated with the lines:
88
89      Resent:\ date
90      Resent:\ addrs
91
92 where each address list contains as many lines as required.  This
93 annotation will be done only if the message is sent directly from
94 .BR dist .
95 If the message is not sent immediately from
96 .BR dist ,
97 .RB \*(lq comp
98 .BR \-use \*(rq
99 may be used to re\-edit and send the constructed
100 message, but the annotations won't take place.  Normally annotations are
101 done inplace in order to preserve any links to the message.  You may use
102 the
103 .B \-noinplace
104 switch to change this.
105 .PP
106 See
107 .BR comp (1)
108 for a description of the
109 .B \-editor
110 and
111 .B \-noedit
112 switches.  Note that while in the editor, the message being resent
113 is available through a link named \*(lq@\*(rq (assuming the default
114 .IR whatnowproc ).
115 In addition, the actual pathname of the message is
116 stored in the environment variable
117 .BR $editalt ,
118 and the pathname of
119 the folder containing the message is stored in the environment variable
120 .BR $mhfolder .
121 .PP
122 The
123 .B \-draftfolder
124 .I +folder
125 and
126 .B \-draftmessage
127 .I msg
128 switches invoke the
129 .B nmh
130 draft folder facility.  This is an advanced (and highly
131 useful) feature.  Consult the
132 .BR mh-draft (5)
133 man page for more information.
134 .PP
135 Upon exiting from the editor,
136 .B dist
137 will invoke the
138 .B whatnow
139 program.  See
140 .BR whatnow (1)
141 for a discussion of available options.  The invocation of this
142 program can be inhibited by using the
143 .B \-nowhatnowproc
144 switch.  (In truth of fact, it is the
145 .B whatnow
146 program which starts the initial edit.  Hence,
147 .B \-nowhatnowproc
148 will prevent any edit from occurring.)
149
150 .SH FILES
151 .fc ^ ~
152 .nf
153 .ta \w'/usr/local/nmh/etc/ExtraBigFileName  'u
154 ^%etcdir%/distcomps~^The standard message skeleton
155 ^or <mh\-dir>/distcomps~^Rather than the standard skeleton
156 ^$HOME/\&.mh\(ruprofile~^The user profile
157 ^<mh\-dir>/draft~^The draft file
158 .fi
159
160 .SH "PROFILE COMPONENTS"
161 .fc ^ ~
162 .nf
163 .ta 2.4i
164 .ta \w'ExtraBigProfileName  'u
165 ^Path:~^To determine the user's nmh directory
166 ^Current\-Folder:~^To find the default current folder
167 ^Draft\-Folder:~^To find the default draft\-folder
168 ^Editor:~^To override the default editor
169 ^fileproc:~^Program to refile the message
170 ^whatnowproc:~^Program to ask the \*(lqWhat now?\*(rq questions
171 .fi
172
173 .SH "SEE ALSO"
174 comp(1), forw(1), repl(1), send(1), whatnow(1)
175
176 .SH DEFAULTS
177 .nf
178 .RB ` +folder "' defaults to the current folder"
179 .RB ` msg "' defaults to cur"
180 .RB ` \-noannotate '
181 .RB ` \-nodraftfolder '
182 .RB ` \-inplace '
183 .fi
184
185 .SH CONTEXT
186 If a folder is given, it will become the current folder.  The message
187 distributed will become the current message.
188
189 .SH HISTORY
190 .B Dist
191 originally used headers of the form
192 .RI \*(lq Distribute\-xxx: \*(rq
193 instead of
194 .RI \*(lq Resent\-xxx: \*(rq.
195 In order to conform with the ARPA Internet standard, RFC\-822, the
196 .RI \*(lq Resent\-xxx: \*(rq
197 form is now used.
198 .B Dist
199 will recognize
200 .RI \*(lq Distribute\-xxx: \*(rq
201 type headers and automatically convert them to
202 .RI \*(lq Resent\-xxx: \*(rq.
203
204 .SH BUGS
205 .B Dist
206 does not rigorously check the message being distributed
207 for adherence to the transport standard, but
208 .B post
209 called by
210 .B send
211 does.  The
212 .B post
213 program will balk (and rightly so) at poorly formatted messages, and
214 .B dist
215 won't correct things for you.
216 .PP
217 If
218 .I whatnowproc
219 is
220 .BR whatnow ,
221 then
222 .B comp
223 uses a built\-in
224 .BR whatnow ,
225 it does not actually run the
226 .B whatnow
227 program.
228 Hence, if you define your own
229 .IR whatnowproc ,
230 don't call it
231 .B whatnow
232 since
233 .B comp
234 won't run it.
235 .PP
236 If your current working directory is not writable, the link named
237 \*(lq@\*(rq is not available.