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