Merge remote-tracking branch 'origin/vendor/LIBRESSL'
[dragonfly.git] / share / doc / usd / 07.mail / mail5.nr
1 .\" Copyright (c) 1980, 1993
2 .\"     The Regents of the University of California.  All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\" 3. Neither the name of the University nor the names of its contributors
13 .\"    may be used to endorse or promote products derived from this software
14 .\"    without specific prior written permission.
15 .\"
16 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
17 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
20 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
21 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
22 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
26 .\" SUCH DAMAGE.
27 .\"
28 .\"     @(#)mail5.nr    8.1 (Berkeley) 6/8/93
29 .\" $FreeBSD: head/share/doc/usd/07.mail/mail5.nr 263142 2014-03-14 03:07:51Z eadler $
30 .\"
31 .bp
32 .sh 1 "Additional features"
33 .pp
34 This section describes some additional commands useful for
35 reading your mail, setting options, and handling lists of messages.
36 .sh 2 "Message lists"
37 .pp
38 Several
39 .i Mail
40 commands accept a list of messages as an argument.
41 Along with
42 .b type
43 and
44 .b delete ,
45 described in section 2,
46 there is the
47 .b from
48 command, which prints the message headers associated with the
49 message list passed to it.
50 The
51 .b from
52 command is particularly useful in conjunction with some of the
53 message list features described below.
54 .pp
55 A
56 .i "message list"
57 consists of a list of message numbers, ranges, and names,
58 separated by spaces or tabs.  Message numbers may be either
59 decimal numbers, which directly specify messages, or one of the
60 special characters
61 .q \(ua
62 .q "."
63 or
64 .q "$"
65 to specify the first relevant, current, or last
66 relevant message, respectively.
67 .i Relevant
68 here means, for most commands
69 .q "not deleted"
70 and
71 .q "deleted"
72 for the
73 .b undelete
74 command.
75 .pp
76 A range of messages consists of two message numbers (of the form
77 described in the previous paragraph) separated by a dash.
78 Thus, to print the first four messages, use
79 .(l
80 type 1\-4
81 .)l
82 and to print all the messages from the current message to the last
83 message, use
84 .(l
85 type .\-$
86 .)l
87 .pp
88 A
89 .i name
90 is a user name.  The user names given in the message list are
91 collected together and each message selected by other means
92 is checked to make sure it was sent by one of the named users.
93 If the message consists entirely of user names, then every
94 message sent by one of those users that is
95 .i relevant
96 (in the sense described earlier)
97 is selected.  Thus, to print every message sent to you by
98 .q root,
99 do
100 .(l
101 type root
102 .)l
103 .pp
104 As a shorthand notation, you can specify simply
105 .q *
106 to get every
107 .i relevant
108 (same sense)
109 message.  Thus,
110 .(l
111 type *
112 .)l
113 prints all undeleted messages,
114 .(l
115 delete *
116 .)l
117 deletes all undeleted messages, and
118 .(l
119 undelete *
120 .)l
121 undeletes all deleted messages.
122 .pp
123 You can search for the presence of a word in subject lines with
124 .b / .
125 For example, to print the headers of all messages that contain the
126 word
127 .q PASCAL,
128 do:
129 .(l
130 from /pascal
131 .)l
132 Note that subject searching ignores upper/lower case differences.
133 .sh 2 "List of commands"
134 .pp
135 This section describes all the
136 .i Mail
137 commands available when
138 receiving mail.
139 .ip "\fB\-\fP\ \ "
140 The
141 .rb \-
142 command goes to the previous message and prints it.  The
143 .rb \-
144 command may be given a decimal number
145 .i n
146 as an argument, in which case the
147 .i n th
148 previous message is gone to and printed.
149 .ip "\fB?\fP\ \ "
150 Prints a brief summary of commands.
151 .ip "\fB!\fP\ \ "
152 Used to preface a command to be executed by the shell.
153 .ip "\fBPrint\fP\ \ "
154 Like
155 .b print ,
156 but also print out ignored header fields.  See also
157 \fBprint\fP, \fBignore\fP and \fBretain\fP.
158 \fBPrint\fP can be abbreviated to \fBP\fP.
159 .ip "\fBReply\fP or \fBRespond\fP\ \ "
160 Note the capital \fBR\fP in the name.
161 Frame a reply to a one or more messages.
162 The reply (or replies if you are using this on multiple messages)
163 will be sent ONLY to the person who sent you the message
164 (respectively, the set of people who sent the messages you are
165 replying to).
166 You can
167 add people using the \fB~t\fP, \fB~c\fP and \fB~b\fP
168 tilde escapes.  The subject in your reply is formed by prefacing the
169 subject in the original message with
170 .q "Re:"
171 unless it already began thus.
172 If the original message included a
173 .q "reply-to"
174 header field, the reply will go
175 .i only
176 to the recipient named by
177 .q "reply-to."
178 You type in your message using the same conventions available to you
179 through the
180 .b mail
181 command.
182 The
183 .b Reply
184 command is especially useful for replying to messages that were sent
185 to enormous distribution groups when you really just want to
186 send a message to the originator.  Use it often.
187 \fBReply\fP (and \fBRespond\fP) can be abbreviated to \fBR\fP.
188 .ip "\fBType\fP\ \ "
189 Identical to the
190 .b Print
191 command.
192 \fBType\fP can be abbreviated to \fBT\fP.
193 .ip "\fBalias\fP\ \ "
194 Define a name to stand for a set of other names.
195 This is used when you want to send messages to a certain
196 group of people and want to avoid retyping their names.
197 For example
198 .(l
199 alias project john sue willie kathryn
200 .)l
201 creates an alias
202 .i project
203 which expands to the four people John, Sue, Willie, and Kathryn.
204 If no arguments are given, all currently-defined aliases are printed.
205 If one argument is given, that alias is printed (if it exists).
206 \fBAlias\fP can be abbreviated to \fBa\fP.
207 .ip "\fBalternates\fP\ \ "
208 If you have accounts on several machines, you may find it convenient
209 to use the /usr/lib/aliases on all the machines except one to direct
210 your mail to a single account.
211 The
212 .b alternates
213 command is used to inform
214 .i Mail
215 that each of these other addresses is really
216 .i you .
217 .i Alternates
218 takes a list of user names and remembers that they are all actually you.
219 When you
220 .b reply
221 to messages that were sent to one of these alternate names,
222 .i Mail
223 will not bother to send a copy of the message to this other address (which
224 would simply be directed back to you by the alias mechanism).
225 If
226 .i alternates
227 is given no argument, it lists the current set of alternate names.
228 .b Alternates
229 is usually used in the .mailrc file.
230 \fBAlternates\fP can be abbreviated to \fBalt\fP.
231 .ip "\fBchdir\fP\ \ "
232 The
233 .b chdir
234 command allows you to change your current directory.
235 .b Chdir
236 takes a single argument, which is taken to be the pathname of
237 the directory to change to.  If no argument is given,
238 .b chdir
239 changes to your home directory.
240 \fBChdir\fP can be abbreviated to \fBc\fP.
241 .ip "\fBcopy\fP\ \ "
242 The
243 .b copy
244 command does the same thing that
245 .b save
246 does, except that it does not mark the messages it is used on
247 for deletion when you quit.
248 \fBCopy\fP can be abbreviated to \fBco\fP.
249 .ip "\fBdelete\fP\ \ "
250 Deletes a list of messages.  Deleted messages can be reclaimed
251 with the
252 .b undelete
253 command.
254 \fBDelete\fP can be abbreviated to \fBd\fP.
255 .ip "\fBdp\fP or \fBdt\fP\ \ "
256 These
257 commands delete the current message and print the next message.
258 They are useful for quickly reading and disposing of mail.
259 If there is no next message, \fImail\fP says ``at EOF.''
260 .ip "\fBedit\fP\ \ "
261 To edit individual messages using the text editor, the
262 .b edit
263 command is provided.  The
264 .b edit
265 command takes a list of messages as described under the
266 .b type
267 command and processes each by writing it into the file
268 Message\c
269 .i x
270 where
271 .i x
272 is the message number being edited and executing the text editor on it.
273 When you have edited the message to your satisfaction, write the message
274 out and quit, upon which
275 .i Mail
276 will read the message back and remove the file.
277 .b Edit
278 can be abbreviated to
279 .b e .
280 .ip "\fBelse\fP\ \ "
281 Marks the end of the then-part of an
282 .b if
283 statement and the beginning of the
284 part to take effect if the condition of the
285 .b if
286 statement is false.
287 .ip "\fBendif\fP\ \ "
288 Marks the end of an
289 .b if
290 statement.
291 .ip "\fBexit\fP or \fBxit\fP\ \ "
292 Leave
293 .i Mail
294 without updating the system mailbox or the file your were reading.
295 Thus, if you accidentally delete several messages, you can use
296 .b exit
297 to avoid scrambling your mailbox.
298 \fBExit\fP can be abbreviated to \fBex\fP or \fBx\fP.
299 .ip "\fBfile\fP\ \ "
300 The same as
301 .b folder .
302 \fBFile\fP can be abbreviated to \fBfi\fP.
303 .ip "\fBfolders\fP\ \ "
304 List the names of the folders in your folder directory.
305 .ip "\fBfolder\fP\ \ "
306 The
307 .b folder
308 command switches to a new mail file or folder.  With no arguments, it
309 tells you which file you are currently reading.  If you give
310 it an argument, it will write out changes (such as deletions)
311 you have made in the current file and read the new file.
312 Some special conventions are recognized for the name:
313 .(b
314 .TS
315 center;
316 c c
317 l a.
318 Name    Meaning
319 _
320 #       Previous file read
321 %       Your system mailbox
322 %name   \fIName\fP's system mailbox
323 &       Your ~/mbox file
324 +folder A file in your folder directory
325 .TE
326 .)b
327 \fBFolder\fP can be abbreviated to \fBfo\fP.
328 .ip "\fBfrom\fP\ \ "
329 The
330 .b from
331 command takes a list of messages and prints out the header lines for each one;
332 hence
333 .(l
334 from joe
335 .)l
336 is the easy way to display all the message headers from \*(lqjoe.\*(rq
337 \fBFrom\fP can be abbreviated to \fBf\fP.
338 .ip "\fBheaders\fP\ \ "
339 When you start up
340 .i Mail
341 to read your mail, it lists the message headers that you have.
342 These headers tell you who each message is from, when they were
343 received, how many lines and characters each message is, and the
344 .q "Subject:"
345 header field of each message, if present.  In addition,
346 .i Mail
347 tags the message header of each message that has been the object
348 of the
349 .b preserve
350 command with a
351 .q P.
352 Messages that have been
353 .b saved
354 or
355 .b written
356 are flagged with a
357 .q *.
358 Finally,
359 .b deleted
360 messages are not printed at all.  If you wish to reprint the current
361 list of message headers, you can do so with the
362 .b headers
363 command.  The
364 .b headers
365 command (and thus the initial header listing)
366 only lists the first so many message headers.
367 The number of headers listed depends on the speed of your
368 terminal.
369 This can be overridden by specifying the number of headers you
370 want with the
371 .i window
372 option.
373 .i Mail
374 maintains a notion of the current
375 .q window
376 into your messages for the purposes of printing headers.
377 Use the
378 .b z
379 command to move forward and back a window.
380 You can move
381 .i Mail's
382 notion of the current window directly to a particular message by
383 using, for example,
384 .(l
385 headers 40
386 .)l
387 to move
388 .i Mail's
389 attention to the messages around message 40.
390 If a ``+'' argument is given, then the next screenful of message headers is
391 printed, and if a ``\-'' argument is given, the previous screenful of message
392 headers is printed.
393 \fBHeaders\fP can be abbreviated to \fBh\fP.
394 .ip "\fBhelp\fP\ \ "
395 Print a brief and usually out of date help message about the commands
396 in
397 .i Mail .
398 The
399 .i man
400 page for
401 .i mail
402 is usually more up-to-date than either the help message or this manual.
403 It is also a synonym for \fB?\fP.
404 .ip "\fBhold\fP\ \ "
405 Arrange to hold a list of messages in the system mailbox, instead
406 of moving them to the file
407 .i mbox
408 in your home directory.  If you set the binary option
409 .i hold ,
410 this will happen by default.
411 It does not override the \fBdelete\fP command.
412 \fBHold\fP can be abbreviated to \fBho\fP.
413 .ip "\fBif\fP\ \ "
414 Commands in your
415 .q .mailrc
416 file can be executed conditionally depending on whether you are
417 sending or receiving mail with the
418 .b if
419 command.  For example, you can do:
420 .(l
421 if receive
422         \fIcommands\fP...
423 endif
424 .)l
425 An
426 .b else
427 form is also available:
428 .(l
429 if send
430         \fIcommands\fP...
431 else
432         \fIcommands\fP...
433 endif
434 .)l
435 Note that the only allowed conditions are
436 .b receive
437 and
438 .b send .
439 .ip "\fBignore\fP \ \ "
440 .b N.B.:
441 .i Ignore
442 has been superseded by
443 .i retain.
444 .br
445 Add the list of header fields named to the
446 .i "ignore list" .
447 Header fields in the ignore list are not printed on your
448 terminal when you print a message.  This allows you to suppress
449 printing of certain machine-generated header fields, such as
450 .i Via
451 which are not usually of interest.  The
452 .b Type
453 and
454 .b Print
455 commands can be used to print a message in its entirety, including
456 ignored fields.
457 If
458 .b ignore
459 is executed with no arguments, it lists the current set of ignored fields.
460 .ip "\fBlist\fP\ \ "
461 List the valid
462 .i Mail
463 commands.
464 \fBList\fP can be abbreviated to \fBl\fP.
465 .\".ip \fBlocal\fP
466 .\"Define a list of local names for this host. This command is useful
467 .\"when the host is known by more than one name. Names in the list
468 .\"may be qualified be the domain of the host. The first name on the local
469 .\"list is the
470 .\".i distinguished
471 .\"name of the host.
472 .\"The names on the local list are used by
473 .\".i Mail
474 .\"to decide which addresses are local to the host.
475 .\"For example:
476 .\".(l
477 .\"local ucbarpa.BERKELEY.ARPA arpa.BERKELEY.ARPA \\
478 .\"     arpavax.BERKELEY.ARPA r.BERKELEY.ARPA \\
479 .\"     ucb-arpa.ARPA
480 .\".)l
481 .\"From this list we see that
482 .\".i "fred@ucbarpa.BERKELEY.ARPA",
483 .\".i "harold@arpa.BERKELEY",
484 .\"and
485 .\".i "larry@r"
486 .\"are all addresses of users on the local host.
487 .\"The
488 .\".b local
489 .\"command is usually not used be general users since it is designed for
490 .\"local configuration; it is usually found in the file /etc/mail.rc.
491 .ip "\fBmail\fP\ \ "
492 Send mail to one or more people.  If you have the
493 .i ask
494 option set,
495 .i Mail
496 will prompt you for a subject to your message.  Then you
497 can type in your message, using tilde escapes as described in
498 section 4 to edit, print, or modify your message.  To signal your
499 satisfaction with the message and send it, type control-d at the
500 beginning of a line, or a . alone on a line if you set the option
501 .i dot .
502 To abort the message, type two interrupt characters (\s-2RUBOUT\s0
503 by default) in a row or use the
504 .b ~q
505 escape.
506 The \fBmail\fP command can be abbreviated to \fBm\fP.
507 .ip "\fBmbox\fP\ \ "
508 Indicate that a list of messages be sent to
509 .i mbox
510 in your home directory when you quit.  This is the default
511 action for messages if you do
512 .i not
513 have the
514 .i hold
515 option set.
516 .ip "\fBnext\fP or \fB+\fP\ \ "
517 The
518 .b next
519 command goes to the next message and types it.  If given a message list,
520 .b next
521 goes to the first such message and types it.  Thus,
522 .(l
523 next root
524 .)l
525 goes to the next message sent by
526 .q root
527 and types it.  The
528 .b next
529 command can be abbreviated to simply a newline, which means that one
530 can go to and type a message by simply giving its message number or
531 one of the magic characters
532 .q "^"
533 .q "."
534 or
535 .q "$".
536 Thus,
537 .(l
538 \&.
539 .)l
540 prints the current message and
541 .(l
542 4
543 .)l
544 prints message 4, as described previously.
545 \fBNext\fP can be abbreviated to \fBn\fP.
546 .ip "\fBpreserve\fP\ \ "
547 Same as
548 .b hold .
549 Cause a list of messages to be held in your system mailbox when you quit.
550 \fBPreserve\fP can be abbreviated to \fBpre\fP.
551 .ip "\fBprint\fP\ \ "
552 Print the specified messages. If the
553 .b crt
554 variable is set, messages longer than the number of lines it indicates
555 are paged through the command specified by the \fBPAGER\fP variable.
556 The \fBprint\fP command can be abbreviated to \fBp\fP.
557 .ip "\fBquit\fP\ \ "
558 Terminates the session, saving all undeleted, unsaved and unwritten messages
559 in the user's \fImbox\fP file in their login directory
560 (messages marked as having been read), preserving all
561 messages marked with \fBhold\fP or \fBpreserve\fP or never referenced
562 in their system mailbox.
563 Any messages that were deleted, saved, written or saved to \fImbox\fP are
564 removed from their system mailbox.
565 If new mail has arrived during the session, the message
566 ``You have new mail'' is given.  If given while editing a mailbox file
567 with the \fB\-f\fP flag, then the edit file is rewritten.
568 A return to the Shell is effected, unless the rewrite of edit file fails,
569 in which case the user can escape with the \fBexit\fP command.
570 \fBQuit\fP can be abbreviated to \fBq\fP.
571 .ip "\fBreply\fP or \fBrespond\fP\ \ "
572 Frame a reply to a single message.
573 The reply will be sent to the
574 person who sent you the message (to which you are replying), plus all
575 the people who received the original message, except you.  You can
576 add people using the \fB~t\fP, \fB~c\fP and \fB~b\fP
577 tilde escapes.  The subject in your reply is formed by prefacing the
578 subject in the original message with
579 .q "Re:"
580 unless it already began thus.
581 If the original message included a
582 .q "reply-to"
583 header field, the reply will go
584 .i only
585 to the recipient named by
586 .q "reply-to."
587 You type in your message using the same conventions available to you
588 through the
589 .b mail
590 command.
591 The \fBreply\fP (and \fBrespond\fP) command can be abbreviated to \fBr\fP.
592 .ip "\fBretain\fP\ \ "
593 Add the list of header fields named to the \fIretained list\fP.
594 Only the header fields in the retain list
595 are shown on your terminal when you print a message.
596 All other header fields are suppressed.
597 The
598 .b Type
599 and
600 .b Print
601 commands can be used to print a message in its entirety.
602 If
603 .b retain
604 is executed with no arguments, it lists the current set of
605 retained fields.
606 .ip "\fBsave\fP\ \ "
607 It is often useful to be able to save messages on related topics
608 in a file.  The
609 .b save
610 command gives you the ability to do this.  The
611 .b save
612 command takes as an argument a list of message numbers, followed by
613 the name of the file in which to save the messages.  The messages
614 are appended to the named file, thus allowing one to keep several
615 messages in the file, stored in the order they were put there.
616 The filename in quotes, followed by the line
617 count and character count is echoed on the user's terminal.
618 An example of the
619 .b save
620 command relative to our running example is:
621 .(l
622 s 1 2 tuitionmail
623 .)l
624 .b Saved
625 messages are not automatically saved in
626 .i mbox
627 at quit time, nor are they selected by the
628 .b next
629 command described above, unless explicitly specified.
630 \fBSave\fP can be abbreviated to \fBs\fP.
631 .ip "\fBset\fP\ \ "
632 Set an option or give an option a value.  Used to customize
633 .i Mail .
634 Section 5.3 contains a list of the options.  Options can be
635 .i binary ,
636 in which case they are
637 .i on
638 or
639 .i off ,
640 or
641 .i valued .
642 To set a binary option
643 .i option
644 .i on ,
645 do
646 .(l
647 set option
648 .)l
649 To give the valued option
650 .i option
651 the value
652 .i value ,
653 do
654 .(l
655 set option=value
656 .)l
657 There must be no space before or after the ``='' sign.
658 If no arguments are given, all variable values are printed.
659 Several options can be specified in a single
660 .b set
661 command.
662 \fBSet\fP can be abbreviated to \fBse\fP.
663 .ip "\fBshell\fP\ \ "
664 The
665 .b shell
666 command allows you to
667 escape to the shell.
668 .b Shell
669 invokes an interactive shell and allows you to type commands to it.
670 When you leave the shell, you will return to
671 .i Mail .
672 The shell used is a default assumed by
673 .i Mail ;
674 you can override this default by setting the valued option
675 .q SHELL,
676 eg:
677 .(l
678 set SHELL=/bin/csh
679 .)l
680 \fBShell\fP can be abbreviated to \fBsh\fP.
681 .ip "\fBsize\fP\ \ "
682 Takes a message list and prints out the size in characters of each
683 message.
684 .ip "\fBsource\fP\ \ "
685 The
686 .b source
687 command reads
688 .i mail
689 commands from a file.  It is useful when you are trying to fix your
690 .q .mailrc
691 file and you need to re-read it.
692 \fBSource\fP can be abbreviated to \fBso\fP.
693 .ip "\fBtop\fP\ \ "
694 The
695 .b top
696 command takes a message list and prints the first five lines
697 of each addressed message.
698 If you wish, you can change the number of lines that
699 .b top
700 prints out by setting the valued option
701 .q "toplines."
702 On a CRT terminal,
703 .(l
704 set toplines=10
705 .)l
706 might be preferred.
707 \fBTop\fP can be abbreviated to \fBto\fP.
708 .ip "\fBtype\fP\ \ "
709 Same as \fBprint\fP.
710 Takes a message list and types out each message on the terminal.
711 The \fBtype\fP command can be abbreviated to \fBt\fP.
712 .ip "\fBundelete\fP \ \"
713 Takes a message list and marks each message as \fInot\fP
714 being deleted.
715 \fBUndelete\fP can be abbreviated to \fBu\fP.
716 .ip "\fBunread\fP\ \ "
717 Takes a message list and marks each message as
718 .i not
719 having been read.
720 \fBUnread\fP can be abbreviated to \fBU\fP.
721 .ip "\fBunset\fP\ \ "
722 Takes a list of option names and discards their remembered values;
723 the inverse of \fBset\fP .
724 .ip "\fBvisual\fP\ \ "
725 It is often useful to be able to invoke one of two editors,
726 based on the type of terminal one is using.  To invoke
727 a display oriented editor, you can use the
728 .b visual
729 command.  The operation of the
730 .b visual
731 command is otherwise identical to that of the
732 .b edit
733 command.
734 .ne 2v+\n(psu
735 .sp \n(psu
736 Both the
737 .b edit
738 and
739 .b visual
740 commands assume some default text editors.  These default editors
741 can be overridden by the valued options
742 .q EDITOR
743 and
744 .q VISUAL
745 for the standard and screen editors.  You might want to do:
746 .(l
747 set EDITOR=/usr/bin/ex VISUAL=/usr/bin/vi
748 .)l
749 \fBVisual\fP can be abbreviated to \fBv\fP.
750 .ip "\fBwrite\fP\ \ "
751 The
752 .b save
753 command always writes the entire message, including the headers,
754 into the file.  If you want to write just the message itself, you
755 can use the
756 .b write
757 command.  The
758 .b write
759 command has the same syntax as the
760 .b save
761 command, and can be abbreviated to simply
762 .b w .
763 Thus, we could write the second message by doing:
764 .(l
765 w 2 file.c
766 .)l
767 As suggested by this example, the
768 .b write
769 command is useful for such tasks as sending and receiving
770 source program text over the message system.
771 The filename in quotes, followed by the line
772 count and character count is echoed on the user's terminal.
773 .ip "\fBz\fP\ \ "
774 .i Mail
775 presents message headers in windowfuls as described under
776 the
777 .b headers
778 command.
779 You can move
780 .i Mail's
781 attention forward to the next window by giving the
782 .(l
783 z+
784 .)l
785 command.  Analogously, you can move to the previous window with:
786 .(l
787 z\-
788 .)l
789 .sh 2 "Custom options"
790 .pp
791 Throughout this manual, we have seen examples of binary and valued options.
792 This section describes each of the options in alphabetical order, including
793 some that you have not seen yet.
794 To avoid confusion, please note that the options are either
795 all lower case letters or all upper case letters.  When I start a sentence
796 such as:
797 .q "Ask"
798 causes
799 .i Mail
800 to prompt you for a subject header,
801 I am only capitalizing
802 .q ask
803 as a courtesy to English.
804 .ip "\fBEDITOR\fP\ \ "
805 The valued option
806 .q EDITOR
807 defines the pathname of the text editor to be used in the
808 .b edit
809 command and ~e.  If not defined, a standard editor is used.
810 .ip "\fBPAGER\fP\ \ "
811 Pathname of the program to use for paginating output when
812 it exceeds \fIcrt\fP lines.
813 A default paginator is used if this option is not defined.
814 .ip "\fBSHELL\fP\ \ "
815 The valued option
816 .q SHELL
817 gives the path name of your shell.  This shell is used for the
818 .b !
819 command and ~! escape.  In addition, this shell expands
820 file names with shell metacharacters like * and ? in them.
821 .ip "\fBVISUAL\fP\ \ "
822 The valued option
823 .q VISUAL
824 defines the pathname of the screen editor to be used in the
825 .b visual
826 command
827 and ~v escape.  A standard screen editor is used if you do not define one.
828 .ip "\fBappend\fP\ \ "
829 The
830 .q append
831 option is binary and
832 causes messages saved in
833 .i mbox
834 to be appended to the end rather than prepended.
835 Normally, \fIMail\fP will put messages in \fImbox\fP
836 in the same order that the system puts messages in your system mailbox.
837 By setting
838 .q append,
839 you are requesting that
840 .i mbox
841 be appended to regardless.  It is in any event quicker to append.
842 .ip "\fBask\fP\ \ "
843 .q "Ask"
844 is a binary option which
845 causes
846 .i Mail
847 to prompt you for the subject of each message you send.
848 If you respond with simply a newline, no subject field will be sent.
849 .ip "\fBaskcc\fP\ \ "
850 .q Askcc
851 is a binary option which
852 causes you to be prompted for additional carbon copy recipients at the
853 end of each message.  Responding with a newline shows your
854 satisfaction with the current list.
855 .ip "\fBautoprint\fP\ \ "
856 .q Autoprint
857 is a binary option which
858 causes the
859 .b delete
860 command to behave like
861 .b dp
862 \*- thus, after deleting a message, the next one will be typed
863 automatically.  This is useful when quickly scanning and deleting
864 messages in your mailbox.
865 .ip "\fBcrt\fP \ \ "
866 The valued option
867 .q crt
868 is used as a threshold to determine how long a message must
869 be before
870 .b PAGER
871 is used to read it.
872 .ip "\fBdebug\fP \ \ "
873 The binary option
874 .q debug
875 causes debugging information to be displayed. Use of this
876 option is the same as using the \fB\-d\fP command line flag.
877 .ip "\fBdot\fP\ \ "
878 .q Dot
879 is a binary option which, if set, causes
880 .i Mail
881 to interpret a period alone on a line as the terminator
882 of the message you are sending.
883 .ip "\fBescape\fP\ \ "
884 To allow you to change the escape character used when sending
885 mail, you can set the valued option
886 .q escape.
887 Only the first character of the
888 .q escape
889 option is used, and it must be doubled if it is to appear as
890 the first character of a line of your message.  If you change your escape
891 character, then ~ loses all its special meaning, and need no longer be doubled
892 at the beginning of a line.
893 .ip "\fBfolder\fP\ \ "
894 The name of the directory to use for storing folders of messages.
895 If this name begins with a `/'
896 .i Mail
897 considers it to be an absolute pathname; otherwise, the folder directory
898 is found relative to your home directory.
899 .ip "\fBhold\fP\ \ "
900 The binary option
901 .q hold
902 causes messages that have been read but not manually dealt with
903 to be held in the system mailbox. This prevents such messages from
904 being automatically swept into your \fImbox\fP file.
905 .ip "\fBignore\fP\ \ "
906 The binary option
907 .q ignore
908 causes \s-2RUBOUT\s0 characters from your terminal to be ignored and echoed
909 as @'s while you are sending mail.  \s-2RUBOUT\s0 characters retain their
910 original meaning in
911 .i Mail
912 command mode.
913 Setting the
914 .q ignore
915 option is equivalent to supplying the
916 .b \-i
917 flag on the command line as described in section 6.
918 .ip "\fBignoreeof\fP\ \ "
919 An option related to
920 .q dot
921 is
922 .q ignoreeof
923 which makes
924 .i Mail
925 refuse to accept a control\-d as the end of a message.
926 .q Ignoreeof
927 also applies to
928 .i Mail
929 command mode.
930 .ip "\fBkeep\fP\ \ "
931 The
932 .q keep
933 option causes
934 .i Mail
935 to truncate your system mailbox instead of deleting it when it
936 is empty.  This is useful if you elect to protect your mailbox, which
937 you would do with the shell command:
938 .(l
939 chmod 600 /var/mail/yourname
940 .)l
941 where
942 .i yourname
943 is your login name.  If you do not do this, anyone can probably read
944 your mail, although people usually don't.
945 .ip "\fBkeepsave\fP\ \ "
946 When you
947 .b save
948 a message,
949 .i Mail
950 usually discards it when you
951 .b quit .
952 To retain all saved messages, set the
953 .q keepsave
954 option.
955 .ip "\fBmetoo\fP\ \ "
956 When sending mail to an alias,
957 .i Mail
958 makes sure that if you are included in the alias, that mail will not
959 be sent to you.  This is useful if a single alias is being used by
960 all members of the group.  If however, you wish to receive a copy of
961 all the messages you send to the alias, you can set the binary option
962 .q metoo.
963 .ip "\fBnoheader\fP\ \ "
964 The binary option
965 .q noheader
966 suppresses the printing of the version and headers when
967 .i Mail
968 is first invoked. Setting this option is the same as using
969 .b \-N
970 on the command line.
971 .ip "\fBnosave\fP\ \ "
972 Normally,
973 when you abort a message with two \s-2RUBOUTs\s0,
974 .i Mail
975 copies the partial letter to the file
976 .q dead.letter
977 in your home directory.  Setting the binary option
978 .q nosave
979 prevents this.
980 .ip "\fBReplyall\fP\ \ "
981 Reverses the sense of
982 .i reply
983 and
984 .i Reply
985 commands.
986 .ip "\fBquiet\fP\ \ "
987 The binary option
988 .q quiet
989 suppresses the printing of the version when
990 .i Mail
991 is first invoked,
992 as well as printing the for example
993 .q "Message 4:"
994 from the
995 .b type
996 command.
997 .ip "\fBrecord\fP\ \ "
998 If you love to keep records, then the
999 valued option
1000 .q record
1001 can be set to the name of a file to save your outgoing mail.
1002 Each new message you send is appended to the end of the file.
1003 .ip "\fBscreen\fP\ \ "
1004 When
1005 .i Mail
1006 initially prints the message headers, it determines the number to
1007 print by looking at the speed of your terminal.  The faster your
1008 terminal, the more it prints.
1009 The valued option
1010 .q screen
1011 overrides this calculation and
1012 specifies how many message headers you want printed.
1013 This number is also used for scrolling with the
1014 .b z
1015 command.
1016 .ip "\fBsendmail\fP\ \ "
1017 To use an alternate mail delivery system, set the
1018 .q sendmail
1019 option to the full pathname of the program to use.  Note:  this is not
1020 for everyone!  Most people should use the default delivery system.
1021 .ip "\fBtoplines\fP\ \ "
1022 The valued option
1023 .q toplines
1024 defines the number of lines that the
1025 .q top
1026 command will print out instead of the default five lines.
1027 .ip "\fBverbose\fP\ \ "
1028 The binary option "verbose" causes
1029 .i Mail
1030 to invoke sendmail with the
1031 .b \-v
1032 flag, which causes it to go into verbose mode and announce expansion
1033 of aliases, etc. Setting the "verbose" option is equivalent to
1034 invoking
1035 .i Mail
1036 with the
1037 .b \-v
1038 flag as described in section 6.