Changed error message to say that blind lists aren't
[mmh] / man / comp.man
1 .\"
2 .\" %nmhwarning%
3 .\"
4 .TH COMP %manext1% "%nmhdate%" MH.6.8 [%nmhversion%]
5 .SH NAME
6 comp \- compose a message
7 .SH SYNOPSIS
8 .HP 5
9 .na
10 .B comp 
11 .RI [ +folder ]
12 .RI [ msg ]
13 .RB [ \-form
14 .IR formfile ]
15 .RB [ \-use " | " \-nouse ]
16 .RB [ \-file
17 .IR file ]
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 [ \-width
27 .IR columns ]
28 .RB [ \-from
29 .IR address ]
30 .RB [ \-to
31 .IR address ]
32 .RB [ \-cc
33 .IR address ]
34 .RB [ \-fcc
35 .IR +folder ]
36 .RB [ \-subject
37 .IR text ]
38 .RB [ \-whatnowproc
39 .IR program ]
40 .RB [ \-nowhatnowproc ]
41 .RB [ \-version ]
42 .RB [ \-help ]
43 .ad
44 .SH DESCRIPTION
45 .B Comp
46 is used to create a new message to be mailed.  It copies a
47 message form to the draft being composed and then invokes an editor on
48 the draft (unless
49 .B \-noedit
50 is given, in which case the initial edit is suppressed).
51 .PP
52 The default message template \*(lqcomponents\*(rq will direct
53 .B comp
54 to construct the message draft as follows:
55 .PP
56 .RS 5
57 .nf
58 From: {from switch} or <Local-Mailbox> or <username@hostname>
59 To: {to switch} or blank
60 cc: {cc switch} or blank
61 Fcc: {fcc switch} or +outbox
62 Subject: {subject switch} or blank
63 --------
64 .fi
65 .RE
66 .PP
67 If a file named
68 .RI \*(lq components \*(rq
69 exists in the user's nmh directory,
70 it will be used instead of this form.  You may specify an alternate
71 forms file with the switch
72 .B \-form
73 .IR formfile .
74 .PP
75 You may also start
76 .B comp
77 using the contents of an existing message
78 as the form.  If you supply either a
79 .I +folder
80 or
81 .I msg
82 argument, that
83 message will be used as the message form.  You may not supply both a
84 .B \-form
85 .I formfile
86 and a
87 .I +folder
88 or
89 .I msg
90 argument.  The line of
91 dashes or a blank line must be left between the header and the body of
92 the message for the message to be identified properly when it is sent
93 (see
94 .BR send (1)).
95 .PP
96 The switch
97 .B \-use
98 directs
99 .B comp
100 to continue editing an already
101 started message.  That is, if a
102 .B comp
103 (or
104 .BR dist ,
105 .BR repl ,
106 or
107 .BR forw )
108 is terminated without sending the draft, the draft can
109 be edited again via
110 .RB \*(lq comp
111 .BR \-use \*(rq.
112 .PP
113 The
114 .B \-file
115 .I file
116 switch says to use the named file as the message draft.
117 .PP
118 Forms that are selected via the
119 .B \-form
120 switch are processed via the
121 .B nmh
122 template system; see 
123 .BR mh\-format (5)
124 for details.  Drafts constructed from another message or with the
125 .B \-use
126 or
127 .B \-file
128 switchs will NOT be processed with
129 .BR mh\-format (5).
130 .PP
131 In addition to the standard
132 .BR mh\-format (5)
133 escapes,
134 the following
135 .I component
136 escapes are either new or have an alternate meaning:
137 .PP
138 .RS 5
139 .nf
140 .ta \w'Escape  'u +\w'Returns  'u
141 .I "Escape      Returns Description"
142 fcc     string  Any folders specified with `\-fcc\ folder'
143 from    string  Any addresses specified with `\-from\ address'
144 to      string  Any addresses specified with `\-to\ address'
145 cc      string  Any addresses specified with `\-cc\ address'
146 subject string  Any text specified with `\-subject\ text'
147 .fi
148 .RE
149 .PP
150 By default the \*(lqTo:\*(rq and \*(lqcc:\*(rq fields are empty.  You may
151 add addresses to these fields with the
152 .B \-to
153 .I address
154 and
155 .B \-cc
156 .I address
157 switches.  You may give these switches multiple times to add multiple
158 addresses.
159 .PP
160 By default the \*(lqFrom:\*(rq field has either the value of the
161 .B Local\-Mailbox
162 profile entry or a system default email address.  This default can be
163 overridden by using the
164 .B \-from
165 .I address
166 switch.  The default mailbox in the \*(lqFcc:\*(rq field is
167 .IR +outbox .
168 This can be overridden by the
169 .B \-fcc
170 switch.
171 .PP
172 Any text you give to the
173 .B \-subject
174 switch will be placed in the \*(lqSubject:\*(rq field in the draft.
175 .PP
176 If the draft already exists,
177 .B comp
178 will ask you as to the disposition
179 of the draft.  A reply of
180 .B quit
181 will abort
182 .BR comp ,
183 leaving the draft intact;
184 .B replace
185 will replace the existing draft with
186 the appropriate form;
187 .B list
188 will display the draft;
189 .B use
190 will use the draft for further composition; and
191 .B refile
192 .I +folder
193 will file the draft in the given folder, and give you a new draft with the
194 appropriate form.  (The
195 .I +folder
196 argument to
197 .B refile
198 is required.)
199 .PP
200 The
201 .B \-draftfolder
202 .I +folder
203 and
204 .B \-draftmessage
205 .I msg
206 switches invoke the
207 .B nmh
208 draft folder facility.  This is an advanced (and highly
209 useful) feature.  Consult the
210 .BR mh-draft (5)
211 man page for more information.
212 .PP
213 The
214 .B \-editor
215 .I editor
216 switch indicates the editor to use for the
217 initial edit.  Upon exiting from the editor,
218 .B comp
219 will invoke the
220 .B whatnow
221 program.  See
222 .BR whatnow (1)
223 for a discussion of
224 available options.  The invocation of this program can be inhibited
225 by using the
226 .B \-nowhatnowproc
227 switch.  (In truth of fact, it is
228 the
229 .I whatnow
230 program which starts the initial edit.  Hence,
231 .B \-nowhatnowproc
232 will prevent any edit from occurring.)
233
234 .SH FILES
235 .fc ^ ~
236 .nf
237 .ta \w'%etcdir%/ExtraBigFileName  'u
238 ^%etcdir%/components~^The standard message skeleton
239 ^or <mh\-dir>/components~^Rather than the standard skeleton
240 ^$HOME/\&.mh\(ruprofile~^The user profile
241 ^<mh\-dir>/draft~^The draft file
242 .fi
243
244 .SH "PROFILE COMPONENTS"
245 .fc ^ ~
246 .nf
247 .ta 2.4i
248 .ta \w'ExtraBigProfileName  'u
249 ^Path:~^To determine the user's nmh directory
250 ^Draft\-Folder:~^To find the default draft\-folder
251 ^Editor:~^To override the default editor
252 ^Msg\-Protect:~^To set mode when creating a new message (draft)
253 ^fileproc:~^Program to refile the message
254 ^whatnowproc:~^Program to ask the \*(lqWhat now?\*(rq questions
255 .fi
256
257 .SH "SEE ALSO"
258 dist(1), forw(1), repl(1), send(1), whatnow(1), mh-profile(5)
259
260 .SH DEFAULTS
261 .nf
262 .RB ` +folder "' defaults to the current folder"
263 .RB ` msg "' defaults to the current message"
264 .RB ` \-nodraftfolder '
265 .RB ` \-nouse '
266 .fi
267
268 .SH CONTEXT
269 None
270
271 .SH BUGS
272 If
273 .I whatnowproc
274 is
275 .BR whatnow ,
276 then
277 .B comp
278 uses a built\-in
279 .BR whatnow ,
280 it does not actually run the
281 .B whatnow
282 program.
283 Hence, if you define your own
284 .IR whatnowproc ,
285 don't call it
286 .B whatnow
287 since
288 .B comp
289 won't run it.