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