Commit | Line | Data |
---|---|---|
91d7df00 | 1 | .\" Copyright (c) 1980 Regents of the University of California. |
2470c0cd | 2 | .\" All rights reserved. |
91d7df00 | 3 | .\" |
2470c0cd KB |
4 | .\" Redistribution and use in source and binary forms are permitted |
5 | .\" provided that the above copyright notice and this paragraph are | |
6 | .\" duplicated in all such forms and that any documentation, | |
7 | .\" advertising materials, and other materials related to such | |
8 | .\" distribution and use acknowledge that the software was developed | |
9 | .\" by the University of California, Berkeley. The name of the | |
10 | .\" University may not be used to endorse or promote products derived | |
11 | .\" from this software without specific prior written permission. | |
12 | .\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR | |
13 | .\" IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED | |
14 | .\" WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. | |
15 | .\" | |
16 | .\" @(#)mail.1 6.9 (Berkeley) %G% | |
91d7df00 | 17 | .\" |
bb04cec6 | 18 | .TH MAIL 1 "" |
91d7df00 KM |
19 | .UC 4 |
20 | .SH NAME | |
21 | mail \- send and receive mail | |
22 | .SH SYNOPSIS | |
23 | .B mail | |
24 | [ | |
692b0644 | 25 | .B \-inv |
dcee403d KM |
26 | ] |
27 | [ | |
28 | .B \-s | |
29 | subject | |
30 | ] | |
31 | [ | |
692b0644 EW |
32 | .B \-c |
33 | cc-addr | |
dcee403d KM |
34 | ] |
35 | [ | |
692b0644 EW |
36 | .B \-b |
37 | bcc-addr | |
dcee403d | 38 | ] |
692b0644 EW |
39 | to-addr... |
40 | .br | |
41 | .B mail | |
dcee403d | 42 | [ |
692b0644 | 43 | .B \-inv |
dcee403d | 44 | ] |
91d7df00 KM |
45 | .B \-f |
46 | [ | |
47 | name | |
48 | ] | |
dcee403d KM |
49 | .br |
50 | .B mail | |
51 | [ | |
692b0644 | 52 | .B \-inv |
91d7df00 | 53 | ] |
dcee403d | 54 | [ |
dcee403d KM |
55 | .B \-u |
56 | user | |
692b0644 | 57 | ] |
91d7df00 KM |
58 | .SH INTRODUCTION |
59 | .I Mail | |
60 | is a intelligent mail processing system, which has | |
61 | a command syntax reminiscent of | |
62 | .I ed | |
63 | with lines replaced by messages. | |
64 | .PP | |
dcee403d KM |
65 | The |
66 | .B \-v | |
67 | flag puts mail into verbose mode; the details of | |
68 | delivery are displayed on the users terminal. | |
69 | The | |
70 | .B \-i | |
71 | flag causes tty interrupt signals to be ignored. This is | |
72 | particularly useful when using | |
73 | .I mail | |
74 | on noisy phone lines. | |
75 | The | |
76 | .B \-n | |
77 | flag inhibits the reading of /usr/lib/Mail.rc. | |
78 | .PP | |
91d7df00 | 79 | .I "Sending mail.\ " |
bfe02f44 | 80 | To send a message to one or more people, |
91d7df00 | 81 | .I mail |
bfe02f44 AH |
82 | can be invoked with arguments which are the names of people to |
83 | whom the mail will be sent. You are then expected to type in | |
84 | your message, followed | |
91d7df00 | 85 | by an \s-2EOT\s0 (control\-D) at the beginning of a line. |
dcee403d KM |
86 | A subject may be specified on the command line by using the |
87 | .B \-s | |
88 | flag. (Only the first argument after the | |
89 | .B \-s | |
90 | flag is used as a subject; be careful to quote subjects | |
692b0644 EW |
91 | containing spaces.) Lists of users to send carbon copies and |
92 | blind carbon copies to may be specified using the | |
93 | .B \-c | |
94 | and | |
95 | .B \-b | |
96 | options, respectively. The single argument following the | |
97 | flag is taken to be a comma-separated list of names. | |
91d7df00 KM |
98 | The section below, labeled |
99 | .I "Replying to or originating mail," | |
100 | describes some features of | |
101 | .I mail | |
102 | available to help you compose your letter. | |
103 | .PP | |
104 | .I "Reading mail.\ " | |
dcee403d | 105 | In normal usage |
91d7df00 KM |
106 | .I mail |
107 | is given no arguments and checks your mail out of the | |
108 | post office, then | |
dcee403d | 109 | prints out a one line header of each message there. |
91d7df00 KM |
110 | The current message is initially the first message (numbered 1) |
111 | and can be printed using the | |
112 | .B print | |
113 | command (which can be abbreviated \fBp\fR). | |
114 | You can move among the messages much as you move between lines in | |
dcee403d | 115 | .IR ed , |
91d7df00 | 116 | with the commands `+' and `\-' moving backwards and forwards, and |
dcee403d | 117 | simple numbers. |
91d7df00 KM |
118 | .PP |
119 | .I "Disposing of mail.\ " | |
120 | After examining a message you can | |
121 | .B delete | |
122 | (\fBd\fR) | |
123 | the message or | |
124 | .B reply | |
125 | (\fBr\fR) | |
126 | to it. | |
127 | Deletion causes the | |
128 | .I mail | |
129 | program to forget about the message. | |
dcee403d | 130 | This is not irreversible; the message can be |
91d7df00 KM |
131 | .B undeleted |
132 | (\fBu\fR) | |
133 | by giving its number, or the | |
134 | .I mail | |
135 | session can be aborted by giving the | |
136 | .B exit | |
137 | (\fBx\fR) | |
138 | command. | |
139 | Deleted messages will, however, usually disappear never to be seen again. | |
140 | .PP | |
141 | .I "Specifying messages.\ " | |
142 | Commands such as | |
143 | .B print | |
144 | and | |
145 | .B delete | |
dcee403d | 146 | can be given a list of message numbers as arguments to apply |
91d7df00 KM |
147 | to a number of messages at once. |
148 | Thus ``delete 1 2'' deletes messages 1 and 2, while ``delete 1\-5'' | |
149 | deletes messages 1 through 5. | |
150 | The special name ``*'' addresses all messages, and ``$'' addresses | |
151 | the last message; thus the command | |
152 | .B top | |
153 | which prints the first few lines of a message could be used in | |
154 | ``top *'' to print the first few lines of all messages. | |
155 | .PP | |
156 | .I "Replying to or originating mail.\ " | |
157 | You can use the | |
158 | .B reply | |
159 | command to | |
160 | set up a response to a message, sending it back to the | |
161 | person who it was from. | |
dcee403d KM |
162 | Text you then type in, up to an end-of-file, |
163 | defines the contents of the message. | |
91d7df00 KM |
164 | While you are composing a message, |
165 | .I mail | |
166 | treats lines beginning with the character `~' specially. | |
167 | For instance, typing ``~m'' (alone on a line) will place a copy | |
692b0644 EW |
168 | of the current message into the response right shifting it by a tabstop |
169 | (see ``tabstr'' variable, below). | |
91d7df00 KM |
170 | Other escapes will set up subject fields, add and delete recipients |
171 | to the message and allow you to escape to an editor to revise the | |
172 | message or to a shell to run some commands. (These options | |
dcee403d | 173 | are given in the summary below.) |
91d7df00 KM |
174 | .PP |
175 | .I "Ending a mail processing session.\ " | |
176 | You can end a | |
177 | .I mail | |
178 | session with the | |
179 | .B quit | |
180 | (\fBq\fR) | |
181 | command. | |
182 | Messages which have been examined go to your | |
183 | .I mbox | |
184 | file unless they have been deleted in which case they are discarded. | |
185 | Unexamined messages go back to the post office. | |
186 | The | |
187 | .B \-f | |
188 | option causes | |
189 | .I mail | |
190 | to read in the contents of your | |
191 | .I mbox | |
192 | (or the specified file) | |
193 | for processing; when you | |
dcee403d | 194 | .BR quit , |
91d7df00 KM |
195 | .I mail |
196 | writes undeleted messages back to this file. | |
dcee403d KM |
197 | The |
198 | .B \-u | |
199 | flag is a short way of doing | |
200 | ||
201 | .B \-f | |
202 | /usr/spool/mail/user". | |
91d7df00 KM |
203 | .PP |
204 | .I "Personal and systemwide distribution lists.\ " | |
205 | It is also possible to create a personal distribution lists so that, | |
206 | for instance, you can send mail to ``cohorts'' and have it go | |
207 | to a group of people. | |
208 | Such lists can be defined by placing a line like | |
209 | .IP | |
dcee403d | 210 | alias cohorts bill ozalp jkf mark kridle@ucbcory |
91d7df00 KM |
211 | .PP |
212 | in the file \&.mailrc in your home directory. | |
dcee403d | 213 | The current list of such aliases can be displayed with the |
91d7df00 KM |
214 | .B alias |
215 | .B (a) | |
216 | command in | |
dcee403d | 217 | .IR mail . |
91d7df00 KM |
218 | System wide distribution lists can be created by editing |
219 | /usr/lib/aliases, see | |
220 | .IR aliases (5) | |
221 | and | |
dcee403d KM |
222 | .IR sendmail (8); |
223 | these are kept in a different syntax. | |
91d7df00 KM |
224 | In mail you send, personal aliases will be expanded in mail sent |
225 | to others so that they will be able to \fBreply\fR to the recipients. | |
226 | System wide \fIaliases\fR are not expanded when the mail is sent, | |
227 | but any reply returned to the machine will have the system wide | |
228 | alias expanded as all mail goes through | |
dcee403d | 229 | .IR sendmail . |
91d7df00 KM |
230 | .PP |
231 | .I "Network mail (ARPA, UUCP, Berknet)\ " | |
dcee403d KM |
232 | See |
233 | .IR mailaddr(7) | |
234 | for a description of network addresses. | |
91d7df00 KM |
235 | .PP |
236 | .I Mail | |
dcee403d | 237 | has a number of options which can be set in the |
91d7df00 KM |
238 | .I \&.mailrc |
239 | file to alter its behavior; thus ``set askcc'' enables the ``askcc'' | |
240 | feature. (These options are summarized below.) | |
241 | .SH SUMMARY | |
242 | (Adapted from the `Mail Reference Manual') | |
dcee403d | 243 | .PP |
91d7df00 KM |
244 | Each command is typed on a line by itself, and may take arguments |
245 | following the command word. The command need not be typed in its | |
246 | entirety \- the first command which matches the typed prefix is used. | |
dcee403d | 247 | For commands which take message lists as arguments, if no message |
91d7df00 KM |
248 | list is given, then the next message forward which satisfies the |
249 | command's requirements is used. If there are no messages forward of | |
250 | the current message, the search proceeds backwards, and if there are no | |
251 | good messages at all, | |
252 | .I mail | |
253 | types ``No applicable messages'' and | |
254 | aborts the command. | |
255 | .TP 12n | |
256 | .B \- | |
257 | Goes to the previous message and prints it out. If given a numeric | |
258 | argument | |
dcee403d | 259 | .IR n , |
91d7df00 | 260 | goes to the |
dcee403d | 261 | .IR n -th |
91d7df00 KM |
262 | previous message and prints it. |
263 | .TP | |
264 | .B ? | |
265 | Prints a brief summary of commands. | |
266 | .TP | |
267 | .B ! | |
268 | Executes the \s-2UNIX\s0 shell command which follows. | |
269 | .TP | |
dcee403d KM |
270 | .B Print |
271 | (\fBP\fR) | |
272 | Like | |
273 | .B print | |
274 | but also prints out ignored header fields. See also | |
275 | .B print | |
bb04cec6 KM |
276 | , |
277 | .B ignore | |
dcee403d | 278 | and |
bb04cec6 | 279 | .B retain. |
dcee403d KM |
280 | .TP |
281 | .B Reply | |
e7dd39cf | 282 | (\fBR\fR) |
dcee403d KM |
283 | Reply to originator. Does not reply to other |
284 | recipients of the original message. | |
285 | .TP | |
286 | .B Type | |
e7dd39cf | 287 | (\fBT\fR) |
dcee403d KM |
288 | Identical to the |
289 | .B Print | |
290 | command. | |
291 | .TP | |
91d7df00 KM |
292 | .B alias |
293 | (\fBa\fR) With no arguments, prints out all currently-defined aliases. With one | |
dcee403d | 294 | argument, prints out that alias. With more than one argument, creates |
692b0644 | 295 | a new alias or changes an old one. |
dcee403d KM |
296 | .TP |
297 | .B alternates | |
298 | (\fBalt\fR) | |
299 | The | |
300 | .B alternates | |
301 | command is useful if you have accounts on several machines. | |
302 | It can be used to inform | |
303 | .I mail | |
304 | that the listed addresses are really you. When you | |
305 | .B reply | |
306 | to messages, | |
307 | .I mail | |
308 | will not send a copy of the message to any of the addresses | |
309 | listed on the | |
310 | .I alternates | |
311 | list. If the | |
312 | .B alternates | |
313 | command is given with no argument, the current set of alternate | |
314 | names is displayed. | |
91d7df00 KM |
315 | .TP |
316 | .B chdir | |
317 | (\fBc\fR) Changes the user's working directory to that specified, if given. If | |
318 | no directory is given, then changes to the user's login directory. | |
319 | .TP | |
dcee403d KM |
320 | .B copy |
321 | (\fBco\fR) | |
322 | The | |
323 | .B copy | |
324 | command does the same thing that | |
325 | .B save | |
326 | does, except that it does not mark the messages it | |
327 | is used on for deletion when you quit. | |
328 | .TP | |
91d7df00 KM |
329 | .B delete |
330 | (\fBd\fR) Takes a list of messages as argument and marks them all as deleted. | |
331 | Deleted messages will not be saved in | |
dcee403d | 332 | .IR mbox , |
91d7df00 KM |
333 | nor will they be available for most other commands. |
334 | .TP | |
335 | .B dp | |
336 | (also \fBdt\fR) Deletes the current message and prints the next message. | |
337 | If there is no next message, | |
338 | .I mail | |
339 | says ``at EOF.'' | |
340 | .TP | |
341 | .B edit | |
342 | (\fBe\fR) Takes a list of messages and points the text editor at each one in | |
343 | turn. On return from the editor, the message is read back in. | |
344 | .TP | |
345 | .B exit | |
346 | (\fBex\fR or \fBx\fR) Effects an immediate return to the Shell without | |
347 | modifying the user's system mailbox, his | |
348 | .I mbox | |
349 | file, or his edit file in | |
dcee403d KM |
350 | .BR \-f . |
351 | .TP | |
352 | .B file | |
353 | (\fBfi\fR) | |
354 | The same as | |
355 | .BR folder . | |
356 | .TP | |
357 | .B folders | |
358 | List the names of the folders in your folder directory. | |
359 | .TP | |
360 | .B folder | |
361 | (\fBfo\fR) | |
362 | The | |
363 | .B folder | |
364 | command switches to a new mail file or folder. With no | |
365 | arguments, it tells you which file you are currently reading. | |
366 | If you give it an argument, it will write out changes (such | |
367 | as deletions) you have made in the current file and read in | |
368 | the new file. Some special conventions are recognized for | |
369 | the name. # means the previous file, % means your system | |
370 | mailbox, %user means user's system mailbox, & means | |
371 | your \~/mbox file, and +folder means a file in your folder | |
372 | directory. | |
91d7df00 KM |
373 | .TP |
374 | .B from | |
375 | (\fBf\fR) Takes a list of messages and prints their message headers. | |
376 | .TP | |
377 | .B headers | |
692b0644 EW |
378 | (\fBh\fR) Lists the current range of headers, which is an 18\-message group. If |
379 | a ``+'' argument is given, then the next 18\-message group is printed, and if | |
380 | a ``\-'' argument is given, the previous 18\-message group is printed. | |
91d7df00 KM |
381 | .TP |
382 | .B help | |
383 | A synonym for ? | |
384 | .TP | |
385 | .B hold | |
386 | (\fBho\fR, also \fBpreserve\fR) Takes a message list and marks each | |
387 | message therein to be saved in the | |
388 | user's system mailbox instead of in | |
dcee403d | 389 | .IR mbox . |
91d7df00 KM |
390 | Does not override the |
391 | .B delete | |
392 | command. | |
393 | .TP | |
dcee403d | 394 | .B ignore |
bb04cec6 KM |
395 | .B N.B.: |
396 | .I Ignore | |
397 | has been superseded by | |
398 | .I retain. | |
399 | .br | |
dcee403d KM |
400 | Add the list of header fields named to the |
401 | .IR "ignored list" . | |
402 | Header fields in the ignore list are not printed | |
403 | on your terminal when you print a message. This | |
404 | command is very handy for suppression of certain machine-generated | |
405 | header fields. The | |
406 | .B Type | |
407 | and | |
408 | .B Print | |
409 | commands can be used to print a message in its entirety, including | |
410 | ignored fields. If | |
411 | .B ignore | |
412 | is executed with no arguments, it lists the current set of | |
413 | ignored fields. | |
414 | .TP | |
91d7df00 KM |
415 | .B mail |
416 | (\fBm\fR) Takes as argument login names and distribution group names and sends | |
417 | mail to those people. | |
418 | .TP | |
dcee403d KM |
419 | .B mbox |
420 | Indicate that a list of messages be sent to | |
421 | .I mbox | |
422 | in your home directory when you quit. This is the default | |
423 | action for messages if you do | |
424 | .I not | |
425 | have the | |
426 | .I hold | |
427 | option set. | |
428 | .TP | |
91d7df00 KM |
429 | .B next |
430 | (\fBn\fR like \fB+\fR or CR) Goes to the next message in sequence and types it. | |
431 | With an argument list, types the next matching message. | |
432 | .TP | |
433 | .B preserve | |
dcee403d | 434 | (\fBpre\fR) |
91d7df00 | 435 | A synonym for |
dcee403d | 436 | .BR hold . |
91d7df00 KM |
437 | .TP |
438 | .B print | |
dcee403d KM |
439 | (\fBp\fR) |
440 | Takes a message list and types out each message on the user's terminal. | |
91d7df00 KM |
441 | .TP |
442 | .B quit | |
443 | (\fBq\fR) Terminates the session, saving all undeleted, unsaved messages in | |
444 | the user's | |
445 | .I mbox | |
446 | file in his login directory, preserving all messages marked with | |
447 | .B hold | |
448 | or | |
449 | .B preserve | |
450 | or never referenced | |
451 | in his system mailbox, and removing all other messages from his system | |
452 | mailbox. If new mail has arrived during the session, the message | |
453 | ``You have new mail'' is given. If given while editing a | |
454 | mailbox file with the | |
455 | .B \-f | |
456 | flag, then the edit file is rewritten. A return to the Shell is | |
457 | effected, unless the rewrite of edit file fails, in which case the user | |
458 | can escape with the | |
459 | .B exit | |
460 | command. | |
461 | .TP | |
462 | .B reply | |
dcee403d KM |
463 | (\fBr\fR) |
464 | Takes a message list and sends mail to the sender and all | |
465 | recipients of the specified message. | |
466 | The default message must not be deleted. | |
91d7df00 KM |
467 | .TP |
468 | .B respond | |
469 | A synonym for | |
dcee403d | 470 | .BR reply . |
91d7df00 | 471 | .TP |
bb04cec6 KM |
472 | .B retain |
473 | Add the list of header fields named to the | |
474 | .IR "retained list" . | |
475 | Only the header fields in the retain list | |
476 | are shown on your terminal when you print a message. | |
477 | All other header fields are suppressed. | |
478 | The | |
479 | .B Type | |
480 | and | |
481 | .B Print | |
482 | commands can be used to print a message in its entirety. | |
483 | If | |
484 | .B retain | |
485 | is executed with no arguments, it lists the current set of | |
486 | retained fields. | |
487 | .TP | |
91d7df00 KM |
488 | .B save |
489 | (\fBs\fR) Takes a message list and a filename and appends each message in | |
490 | turn to the end of the file. The filename in quotes, followed by the line | |
491 | count and character count is echoed on the user's terminal. | |
492 | .TP | |
493 | .B set | |
494 | (\fBse\fR) With no arguments, prints all variable values. Otherwise, sets | |
495 | option. Arguments are of the form | |
496 | ``option=value'' | |
bb04cec6 | 497 | (no space before or after =) or |
91d7df00 | 498 | ``option.'' |
692b0644 EW |
499 | Quotation marks may be placed around any part of the assignment statement to |
500 | quote blanks or tabs, i.e. ``set tabstr="-> "''. | |
91d7df00 | 501 | .TP |
02c3f688 EW |
502 | .B saveignore |
503 | \fBSaveignore\fP is to \fBsave\fP what \fBignore\fP is to \fBprint\fP | |
504 | and \fBtype\fP. Header fields thus marked are filtered out when | |
505 | saving a message by \fBsave\fP or when automatically saving to mbox. | |
506 | .TP | |
507 | .B saveretain | |
508 | \fBSaveretain\fP is to \fBsave\fP what \fBretain\fP is to \fBprint\fP | |
509 | and \fBtype\fP. Header fields thus marked are the only ones saved | |
510 | with a message when saving by \fBsave\fP or when automatically saving to mbox. | |
511 | \fBSaveretain\fP overrides \fBsaveignore\fP. | |
512 | .TP | |
91d7df00 KM |
513 | .B shell |
514 | (\fBsh\fR) Invokes an interactive version of the shell. | |
515 | .TP | |
516 | .B size | |
517 | Takes a message list and prints out the size in characters of each | |
518 | message. | |
519 | .TP | |
dcee403d KM |
520 | .B source |
521 | (\fBso\fR) | |
522 | The | |
523 | .B source | |
524 | command reads | |
525 | .I mail | |
526 | commands from a file. | |
527 | .TP | |
91d7df00 KM |
528 | .B top |
529 | Takes a message list and prints the top few lines of each. The number of | |
530 | lines printed is controlled by the variable | |
531 | .B toplines | |
532 | and defaults to five. | |
533 | .TP | |
534 | .B type | |
535 | (\fBt\fR) A synonym for | |
dcee403d | 536 | .BR print . |
91d7df00 KM |
537 | .TP |
538 | .B unalias | |
539 | Takes a list of names defined by | |
540 | .B alias | |
541 | commands and discards the remembered groups of users. The group names | |
542 | no longer have any significance. | |
543 | .TP | |
544 | .B undelete | |
634278dc | 545 | (\fBu\fR) Takes a message list and marks each message as |
91d7df00 KM |
546 | .I not |
547 | being deleted. | |
548 | .TP | |
634278dc S |
549 | .B unread |
550 | (\fBU\fR) Takes a message list and marks each message as | |
551 | .I not | |
552 | having been read. | |
553 | .TP | |
91d7df00 KM |
554 | .B unset |
555 | Takes a list of option names and discards their remembered values; | |
556 | the inverse of | |
dcee403d | 557 | .BR set . |
91d7df00 KM |
558 | .TP |
559 | .B visual | |
560 | (\fBv\fR) Takes a message list and invokes the display editor on each message. | |
561 | .TP | |
562 | .B write | |
b3f2d791 S |
563 | (\fBw\fR) Similar to |
564 | .BR save , | |
565 | except that | |
566 | .I only | |
567 | the message body (\fIwithout\fP the header) is saved. | |
568 | Extremely useful for such tasks as sending and receiving source | |
569 | program text over the message system. | |
91d7df00 KM |
570 | .TP |
571 | .B xit | |
572 | (\fBx\fR) A synonym for | |
dcee403d KM |
573 | .BR exit . |
574 | .TP | |
575 | .B z | |
576 | .I Mail | |
577 | presents message headers in windowfuls as described under the | |
578 | .B headers | |
579 | command. You can move | |
580 | .IR mail 's | |
581 | attention forward to the next window with the | |
582 | .B z | |
583 | command. Also, you can move to the previous window by using | |
584 | .BR z\- . | |
91d7df00 KM |
585 | .PP |
586 | Here is a summary of the tilde escapes, | |
587 | which are used when composing messages to perform | |
588 | special functions. Tilde escapes are only recognized at the beginning | |
589 | of lines. The name | |
590 | ``tilde\ escape'' | |
591 | is somewhat of a misnomer since the actual escape character can be set | |
592 | by the option | |
593 | .B escape. | |
594 | .TP 12n | |
dcee403d | 595 | .BR ~! command |
91d7df00 KM |
596 | Execute the indicated shell command, then return to the message. |
597 | .TP | |
cb530a2d KM |
598 | \fB~b\fR name ... |
599 | Add the given names to the list of carbon copy recipients but do not make | |
600 | the names visible in the Cc: line ("blind" carbon copy). | |
601 | .TP | |
91d7df00 KM |
602 | \fB~c\fR name ... |
603 | Add the given names to the list of carbon copy recipients. | |
604 | .TP | |
605 | .B ~d | |
606 | Read the file ``dead.letter'' from your home directory into the message. | |
607 | .TP | |
608 | .B ~e | |
609 | Invoke the text editor on the message collected so far. After the | |
610 | editing session is finished, you may continue appending text to the | |
611 | message. | |
612 | .TP | |
dcee403d KM |
613 | \fB~f\fR messages |
614 | Read the named messages into the message being sent. | |
615 | If no messages are specified, read in the current message. | |
616 | .TP | |
91d7df00 KM |
617 | .B ~h |
618 | Edit the message header fields by typing each one in turn and allowing | |
619 | the user to append text to the end or modify the field by using the | |
620 | current terminal erase and kill characters. | |
621 | .TP | |
622 | \fB~m\fR messages | |
623 | Read the named messages into the message being sent, shifted right one | |
624 | tab. If no messages are specified, read the current message. | |
625 | .TP | |
626 | .B ~p | |
627 | Print out the message collected so far, prefaced by the message header | |
628 | fields. | |
629 | .TP | |
630 | .B ~q | |
631 | Abort the message being sent, copying the message to | |
632 | ``dead.letter'' | |
633 | in your home directory if | |
634 | .B save | |
635 | is set. | |
636 | .TP | |
637 | \fB~r\fR filename | |
638 | Read the named file into the message. | |
639 | .TP | |
640 | \fB~s\fR string | |
641 | Cause the named string to become the current subject field. | |
642 | .TP | |
643 | \fB~t\fR name ... | |
644 | Add the given names to the direct recipient list. | |
645 | .TP | |
646 | .B ~v | |
647 | Invoke an alternate editor (defined by the VISUAL option) on the | |
648 | message collected so far. Usually, the alternate editor will be a | |
649 | screen editor. After you quit the editor, you may resume appending | |
650 | text to the end of your message. | |
651 | .TP | |
652 | \fB~w\fR filename | |
653 | Write the message onto the named file. | |
654 | .TP | |
655 | \fB~\||\|\fRcommand | |
656 | Pipe the message through the command as a filter. If the command gives | |
657 | no output or terminates abnormally, retain the original text of the | |
658 | message. The command | |
659 | .IR fmt (1) | |
660 | is often used as | |
661 | .I command | |
662 | to rejustify the message. | |
663 | .TP | |
dcee403d | 664 | .BR ~~ string |
91d7df00 KM |
665 | Insert the string of text in the message prefaced by a single ~. If |
666 | you have changed the escape character, then you should double | |
667 | that character in order to send it. | |
668 | .PP | |
669 | Options are controlled via the | |
670 | .B set | |
671 | and | |
672 | .B unset | |
673 | commands. Options may be either binary, in which case it is only | |
bfe02f44 | 674 | significant to see whether they are set or not; or string, in which |
91d7df00 KM |
675 | case the actual value is of interest. |
676 | The binary options include the following: | |
677 | .TP 15n | |
678 | .B append | |
679 | Causes messages saved in | |
680 | .I mbox | |
681 | to be appended to the end rather than prepended. | |
682 | (This is set in | |
683 | /usr/lib/Mail.rc | |
684 | on version 7 systems.) | |
685 | .TP | |
686 | .B ask | |
687 | Causes | |
688 | .I mail | |
689 | to prompt you for the subject of each message you send. If | |
690 | you respond with simply a newline, no subject field will be sent. | |
691 | .TP | |
692 | .B askcc | |
693 | Causes you to be prompted for additional carbon copy recipients at the | |
694 | end of each message. Responding with a newline indicates your | |
695 | satisfaction with the current list. | |
696 | .TP | |
697 | .B autoprint | |
698 | Causes the | |
699 | .B delete | |
700 | command to behave like | |
701 | .B dp | |
702 | \- thus, after deleting a message, the next one will be typed | |
703 | automatically. | |
704 | .TP | |
dcee403d KM |
705 | .B debug |
706 | Setting the binary option | |
707 | .I debug | |
708 | is the same as specifying | |
709 | .B \-d | |
710 | on the command line and causes | |
711 | .I mail | |
712 | to output all sorts of information useful for debugging | |
713 | .IR mail . | |
714 | .TP | |
715 | .B dot | |
716 | The binary option | |
717 | .I dot | |
718 | causes | |
719 | .I mail | |
720 | to interpret a period alone on a line as the terminator | |
721 | of a message you are sending. | |
722 | .TP | |
723 | .B hold | |
724 | This option is used to hold messages in the system mailbox | |
725 | by default. | |
726 | .TP | |
91d7df00 KM |
727 | .B ignore |
728 | Causes interrupt signals from your terminal to be ignored and echoed as | |
729 | @'s. | |
730 | .TP | |
dcee403d KM |
731 | .B ignoreeof |
732 | An option related to | |
733 | .I dot | |
734 | is | |
735 | .I ignoreeof | |
736 | which makes | |
737 | .I mail | |
738 | refuse to accept a control-d as the end of a message. | |
739 | .I Ignoreeof | |
740 | also applies to | |
741 | .I mail | |
742 | command mode. | |
743 | .TP | |
91d7df00 KM |
744 | .B metoo |
745 | Usually, when a group is expanded that contains the sender, the sender | |
746 | is removed from the expansion. Setting this option causes the sender | |
747 | to be included in the group. | |
748 | .TP | |
dcee403d KM |
749 | .B nosave |
750 | Normally, when you abort a message with two \s-2RUBOUT\s0, | |
751 | .I mail | |
752 | copies the partial letter to the file ``dead.letter'' | |
753 | in your home directory. Setting the binary option | |
754 | .I nosave | |
755 | prevents this. | |
756 | .TP | |
634278dc S |
757 | .B Replyall |
758 | Reverses the sense of | |
759 | .I reply | |
760 | and | |
761 | .I Reply | |
762 | commands. | |
763 | .TP | |
91d7df00 KM |
764 | .B quiet |
765 | Suppresses the printing of the version when first invoked. | |
766 | .TP | |
dcee403d KM |
767 | .B verbose |
768 | Setting the option | |
769 | .I verbose | |
770 | is the same as using the | |
771 | .B \-v | |
772 | flag on the command line. When mail runs in verbose mode, | |
773 | the actual delivery of messages is displayed on he users | |
774 | terminal. | |
91d7df00 KM |
775 | .PP |
776 | The following options have string values: | |
777 | .TP 15n | |
778 | EDITOR | |
779 | Pathname of the text editor to use in the | |
780 | .B edit | |
781 | command and ~e escape. If not defined, then a default editor is used. | |
782 | .TP | |
634278dc S |
783 | PAGER |
784 | Pathname of the program to use in the | |
785 | .B more | |
786 | command or when | |
787 | .I crt | |
692b0644 EW |
788 | variable is set. The default paginator |
789 | .I more(1) | |
790 | is used if this option is not defined. | |
634278dc | 791 | .TP |
91d7df00 KM |
792 | SHELL |
793 | Pathname of the shell to use in the | |
794 | .B ! | |
795 | command and the ~! escape. A default shell is used if this option is | |
796 | not defined. | |
797 | .TP | |
798 | VISUAL | |
799 | Pathname of the text editor to use in the | |
800 | .B visual | |
801 | command and ~v escape. | |
802 | .TP | |
dcee403d KM |
803 | .B crt |
804 | The valued option | |
805 | .I crt | |
806 | is used as a threshold to determine how long a message must | |
807 | be before | |
634278dc | 808 | .B PAGER |
dcee403d KM |
809 | is used to read it. |
810 | .TP | |
91d7df00 KM |
811 | .B escape |
812 | If defined, the first character of this option gives the character to | |
813 | use in the place of ~ to denote escapes. | |
814 | .TP | |
dcee403d KM |
815 | .B folder |
816 | The name of the directory to use for storing folders of | |
817 | messages. If this name begins with a `/', | |
818 | .I mail | |
819 | considers it to be an absolute pathname; otherwise, the | |
820 | folder directory is found relative to your home directory. | |
821 | .TP | |
91d7df00 KM |
822 | .B record |
823 | If defined, gives the pathname of the file used to record all outgoing | |
824 | mail. If not defined, then outgoing mail is not so saved. | |
825 | .TP | |
692b0644 EW |
826 | .B tabstr |
827 | String used by the ``~m'' tilde escape for tabbing messages, in place of | |
828 | the normal tab character (^I). Be sure to quote the value if it contains | |
829 | spaces or tabs. | |
830 | .TP | |
91d7df00 KM |
831 | .B toplines |
832 | If defined, gives the number of lines of a message to be printed out | |
833 | with the | |
834 | .B top | |
835 | command; normally, the first five lines are printed. | |
836 | .SH FILES | |
837 | .if n .ta 2.5i | |
838 | .if t .ta 1.8i | |
839 | /usr/spool/mail/* post office | |
840 | .br | |
841 | ~/mbox your old mail | |
842 | .br | |
843 | ~/.mailrc file giving initial mail commands | |
844 | .br | |
845 | /tmp/R# temporary for editor escape | |
846 | .br | |
847 | /usr/lib/Mail.help* help files | |
848 | .br | |
849 | /usr/lib/Mail.rc system initialization file | |
850 | .br | |
dcee403d | 851 | Message* temporary for editing messages |
91d7df00 | 852 | .SH "SEE ALSO" |
dcee403d KM |
853 | binmail(1), fmt(1), newaliases(1), aliases(5), |
854 | .br | |
855 | mailaddr(7), sendmail(8) | |
91d7df00 KM |
856 | .br |
857 | `The Mail Reference Manual' | |
dcee403d KM |
858 | .SH BUGS |
859 | There are many flags that are not documented here. Most are | |
860 | not useful to the general user. | |
861 | .br | |
862 | Usually, | |
863 | .I mail | |
864 | is just a link to | |
865 | .IR Mail , | |
866 | which can be confusing. | |
91d7df00 KM |
867 | .SH AUTHOR |
868 | Kurt Shoens | |
692b0644 | 869 |