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