Renamed -version switch to -Version to remove the conflict with -verbose.
[mmh] / man / send.man1
1 .\"
2 .\" %nmhwarning%
3 .\"
4 .TH SEND %manext1% "%nmhdate%" MH.6.8 [%nmhversion%]
5 .SH NAME
6 send \- send a message
7 .SH SYNOPSIS
8 .HP 5
9 .na
10 .B send
11 .RB [ \-alias
12 .IR aliasfile ]
13 .RB [ \-verbose " | " \-noverbose ]
14 .RB [ \-watch " | " \-nowatch ]
15 .RB [ msg
16 \&...]
17 .RB [ \-Version ]
18 .RB [ \-help ]
19 .ad
20 .SH DESCRIPTION
21 .B Send
22 will cause each of the specified messages to be delivered
23 to each of the destinations in the \*(lqTo:\*(rq, \*(lqCc:\*(rq,
24 \*(lqBcc:\*(rq, \*(lqDcc:\*(rq, and \*(lqFcc:\*(rq fields of the message.  If
25 .B send
26 is re\-distributing a message, as invoked from
27 .BR dist ,
28 then the
29 corresponding \*(lqResent\-xxx\*(rq fields are examined instead.
30 .PP
31 .B send
32 uses the program
33 .B spost
34 to do the actual delivery of the messages.
35 Most of the features attributed to
36 .B send
37 are actually performed by
38 .BR spost .
39 .PP
40 The draft is scanned for attachment header fields.
41 Their name defaults to ``Attach'', but may be changed by the value of the
42 .I Attachment-Header
43 profile entry.
44 If such header fields are found, or the body contains non-ASCII characters,
45 the message is converted to a MIME message.
46 This conversion occurs before all other processing.
47 .PP
48 The first part of the MIME message is the draft body if the body is non-empty.
49 The body of each attachment header field is interpreted as a file name,
50 and each file named is included as a separate part in the MIME message.
51 .PP
52 For file names with dot suffixes, the context is scanned for a
53 .I show-suffix-
54 entry for that suffix.
55 The content-type for the part is taken from that context entry if a match is
56 found.
57 If no match is found or the file does not have a dot suffix, the content-type
58 is text/plain if the file contains only ASCII characters or
59 application/octet-stream otherwise.
60 .PP
61 The last component of the path name is taken as the name of the MIME parts.
62 A message part header for an attachment might be:
63 .PP
64 .nf
65 Content-Type: text/plain; name="VERSION"; charset="us-ascii"
66 Content-Description: VERSION
67 Content-Disposition: attachment; filename="VERSION"
68 .fi
69 .PP
70 If
71 .B \-verbose
72 is specified,
73 .B send
74 will indicate the interactions
75 occurring with the transport system, prior to actual delivery.
76 If
77 .B \-watch
78 is specified
79 .B send
80 will monitor the delivery of local
81 and network mail.  Hence, by specifying both switches, a large detail
82 of information can be gathered about each step of the message's entry
83 into the transport system.
84 .PP
85 .B Send
86 with no
87 .I msg
88 argument will send the current message in the draft folder.
89 .B Send
90 always takes messages from the draft folder.
91 (But, a
92 .I +folder
93 argument might be added in the future.)
94 Consult the
95 .BR mh-draft (7)
96 man page for more information.
97 .PP
98 Once the transport system has successfully accepted custody of the
99 message, the message will be renamed with a leading comma, which allows
100 it to be retrieved until the next draft message is sent.  If there are
101 errors in the formatting of the message,
102 .B send
103 will abort with a
104 (hopefully) helpful error message.
105 .PP
106 If a \*(lqBcc:\*(rq field is encountered, its addresses will be used for
107 delivery, and the \*(lqBcc:\*(rq field will be removed from the message
108 sent to sighted recipients.  The blind recipients will receive an entirely
109 new message with a minimal set of headers.  Included in the body of the
110 message will be a copy of the message sent to the sighted recipients.
111 .PP
112 If a \*(lqDcc:\*(rq field is encountered, its addresses will be used for
113 delivery, and the \*(lqDcc:\*(rq field will be removed from the message.  The
114 blind recipients will receive the same message sent to the sighted
115 recipients. *WARNING* Recipients listed in the \*(lqDcc:\*(rq field receive no
116 explicit indication that they have received a \*(lqblind copy\*(rq.
117 This can cause blind recipients to
118 inadvertently reply to all of the sighted recipients of the
119 original message, revealing that they received a blind copy.
120 On the other hand, since a normal reply to a message sent
121 via a \*(lqBcc:\*(rq field
122 will generate a reply only to the sender of the original message,
123 it takes extra effort in most mailers to reply to the included
124 message, and so would usually only be done deliberately, rather
125 than by accident.
126 .PP
127 Prior to sending the message, the fields \*(lqFrom:\ user@local\*(rq,
128 and \*(lqDate:\ now\*(rq will be appended to the headers in the message.
129 If the environment variable
130 .B $SIGNATURE
131 is set, then its value
132 is used as your personal name when constructing the \*(lqFrom:\*(rq
133 line of the message.  If this environment variable is not set, then
134 .B send
135 will consult the profile entry \*(lqSignature\*(rq for
136 this information.
137 .PP
138 If
139 .B send
140 is re\-distributing a message (when invoked by
141 .BR dist ),
142 then \*(lqResent\-\*(rq will be prepended to each of these
143 fields: \*(lqFrom:\*(rq, \*(lqDate:\*(rq, and \*(lqMessage\-ID:\*(rq.
144 If the message already contains a \*(lqFrom:\*(rq field, then a
145 \*(lqSender: user@local\*(rq field will be added as well.  (An already
146 existing \*(lqSender:\*(rq field is an error!)
147 .PP
148 If an \*(lqFcc:\ folder\*(rq is encountered, the message will be copied
149 to the specified folder for the sender in the format in which it will
150 appear to any non\-Bcc receivers of the message.  That is, it will have
151 the appended fields and field reformatting.  The \*(lqFcc:\*(rq fields
152 will be removed from all outgoing copies of the message.
153 .PP
154 The files specified by the profile entry \*(lqAliasfile:\*(rq and any
155 additional alias files given by the
156 .B \-alias
157 .I aliasfile
158 switch will be
159 read (more than one file, each preceded by
160 .BR \-alias ,
161 can be named).
162 See
163 .BR mh\-alias (5)
164 for more information.
165
166 .SH FILES
167 .fc ^ ~
168 .nf
169 .ta \w'%etcdir%/ExtraBigFileName  'u
170 ^$HOME/.mmh/profile~^The user profile
171 ^+drafts~^The draft folder
172 .fi
173
174 .SH "PROFILE COMPONENTS"
175 .fc ^ ~
176 .nf
177 .ta 2.4i
178 .ta \w'ExtraBigProfileName  'u
179 ^Path:~^To determine the user's mail storage
180 ^Draft\-Folder:~^To set the default draft\-folder
181 ^Aliasfile:~^For a default alias file
182 ^Signature:~^To determine the user's mail signature
183 ^Attachment\-Header:~^To set the name of the attachment header field
184 .fi
185
186 .SH "SEE ALSO"
187 comp(1), dist(1), forw(1), repl(1), mh\-alias(5), spost(8)
188
189 .SH DEFAULTS
190 .nf
191 .RB ` msg "' defaults to the current message in the draft folder"
192 .RB ` \-noverbose '
193 .RB ` \-nowatch '
194 .fi
195
196 .SH CONTEXT
197 None
198
199 .SH BUGS
200 Under some configurations, it is not possible to monitor the mail delivery
201 transaction;
202 .B \-watch
203 is a no-op on those systems.