=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/mail/mail.1,v retrieving revision 1.21 retrieving revision 1.22 diff -c -r1.21 -r1.22 *** src/usr.bin/mail/mail.1 1998/11/11 23:01:45 1.21 --- src/usr.bin/mail/mail.1 1998/11/19 23:23:49 1.22 *************** *** 1,4 **** ! .\" $OpenBSD: mail.1,v 1.21 1998/11/11 23:01:45 aaron Exp $ .\" .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. --- 1,4 ---- ! .\" $OpenBSD: mail.1,v 1.22 1998/11/19 23:23:49 aaron Exp $ .\" .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. *************** *** 45,52 **** .Nm mail .Op Fl iInv .Op Fl s Ar subject ! .Op Fl c Ar cc-addr ! .Op Fl b Ar bcc-addr .Ar to-addr Op Ar ... .Op Fl Ar sendmail-options Op Ar ... .Nm mail --- 45,52 ---- .Nm mail .Op Fl iInv .Op Fl s Ar subject ! .Op Fl c Ar list ! .Op Fl b Ar list .Ar to-addr Op Ar ... .Op Fl Ar sendmail-options Op Ar ... .Nm mail *************** *** 56,62 **** .Nm mail .Op Fl iInNv .Op Fl u Ar user ! .Sh INTRODUCTION .Nm mail is an intelligent mail processing system which has a command syntax reminiscent of --- 56,62 ---- .Nm mail .Op Fl iInNv .Op Fl u Ar user ! .Sh DESCRIPTION .Nm mail is an intelligent mail processing system which has a command syntax reminiscent of *************** *** 74,131 **** .Nm mail on noisy phone lines. .It Fl I ! Forces mail to run in interactive mode even when ! input isn't a terminal. ! In particular, the ! .Sq Ic \&~ ! special ! character when sending mail is only active in interactive mode. .It Fl n Inhibits reading .Pa /etc/mail.rc upon startup. .It Fl N ! Inhibits the initial display of message headers when reading mail or editing a mail folder. .It Fl s Ar subject Specify subject on command line (only the first argument after the .Fl s flag is used as a subject; be careful to quote subjects ! containing spaces.) ! .It Fl c Ar cc-addr Send carbon copies to .Ar list of users. ! .It Fl b Ar bcc-addr Send blind carbon copies to .Ar list . ! List should be a comma-separated list of names. ! .It Fl f ! Read in the contents of your ! .Ar mbox ! (or the specified file) ! for processing; when you ! .Ar quit , .Nm mail writes undeleted messages back to this file. .It Fl u Ar user Is equivalent to: .Pp .Dl mail -f /var/mail/user ! Except that locking is done. .El .Ss Startup actions ! At startup time .Nm mail will execute commands in the system command files .Pa /usr/share/misc/mail.rc , ! .Pa /usr/local/etc/mail.rc , and .Pa /etc/mail.rc in order unless explicitly told not to by using the .Fl n ! option. Next, the commands in the user's personal command file .Pa ~/.mailrc are executed. .Nm mail --- 74,132 ---- .Nm mail on noisy phone lines. .It Fl I ! Forces ! .Nm mail ! to run in interactive mode, even when input is not a terminal. ! In particular, the special ! .Ic \&~ ! command character, used when sending mail, is only available interactively. .It Fl n Inhibits reading .Pa /etc/mail.rc upon startup. .It Fl N ! Inhibits initial display of message headers when reading mail or editing a mail folder. .It Fl s Ar subject Specify subject on command line (only the first argument after the .Fl s flag is used as a subject; be careful to quote subjects ! containing spaces). ! .It Fl c Ar list Send carbon copies to .Ar list of users. ! .Ar list ! should be a comma separated list of names. ! .It Fl b Ar list Send blind carbon copies to .Ar list . ! .It Fl f Ar name ! Read in the contents of your mailbox ! (or the specified file ! .Ar name ) ! for processing; when you quit, .Nm mail writes undeleted messages back to this file. .It Fl u Ar user Is equivalent to: .Pp .Dl mail -f /var/mail/user ! .Pp ! except that locking is done. .El .Ss Startup actions ! At startup time, .Nm mail will execute commands in the system command files .Pa /usr/share/misc/mail.rc , ! .Pa /usr/local/etc/mail.rc and .Pa /etc/mail.rc in order unless explicitly told not to by using the .Fl n ! option. Next, the commands in the user's personal command file .Pa ~/.mailrc are executed. .Nm mail *************** *** 139,146 **** whom the mail will be sent. You are then expected to type in your message, followed ! by an ! .Sq Li control\-D at the beginning of a line. The section below, .Ar Replying to or originating mail , --- 140,147 ---- whom the mail will be sent. You are then expected to type in your message, followed ! by a control-D ! .Pq Sq ^D at the beginning of a line. The section below, .Ar Replying to or originating mail , *************** *** 149,178 **** available to help you compose your letter. .Pp .Ss Reading mail ! In normal usage .Nm mail is given no arguments and checks your mail out of the post office, then prints out a one line header of each message found. ! The current message is initially the first message (numbered 1) and can be printed using the .Ic print command (which can be abbreviated .Ic p ) . ! You can move among the messages much as you move between lines in ! .Xr \&ed 1 , ! with the commands ! .Ql Ic \&+ and ! .Ql Ic \&\- ! moving backwards and forwards, and ! simple numbers. .Pp ! .Ss Disposing of mail. After examining a message you can .Ic delete .Pq Ic d ! the message or .Ic reply .Pq Ic r to it. --- 150,179 ---- available to help you compose your letter. .Pp .Ss Reading mail ! In normal usage, .Nm mail is given no arguments and checks your mail out of the post office, then prints out a one line header of each message found. ! The current message is initially set to the first message (numbered 1) and can be printed using the .Ic print command (which can be abbreviated .Ic p ) . ! Moving among the messages is much like moving between lines in ! .Xr ed 1 ; ! you may use ! .Ic \&+ and ! .Ic \&- ! to shift forwards and backwards, or simply enter a message number to move ! directly. .Pp ! .Ss Disposing of mail After examining a message you can .Ic delete .Pq Ic d ! or .Ic reply .Pq Ic r to it. *************** *** 188,194 **** .Ic exit .Pq Ic x command. ! Deleted messages will, however, usually disappear never to be seen again. .Pp .Ss Specifying messages Commands such as --- 189,195 ---- .Ic exit .Pq Ic x command. ! Deleted messages, however, will usually disappear, never to be seen again. .Pp .Ss Specifying messages Commands such as *************** *** 198,219 **** can be given a list of message numbers as arguments to apply to a number of messages at once. Thus ! .Dq Li delete 1 2 deletes messages 1 and 2, while ! .Dq Li delete 1\-5 deletes messages 1 through 5. The special name ! .Ql Li \&* ! addresses all messages, and ! .Ql Li \&$ addresses the last message; thus the command .Ic top which prints the first few lines of a message could be used in ! .Dq Li top \&* to print the first few lines of all messages. .Pp ! .Ss Replying to or originating mail. You can use the .Ic reply command to --- 199,220 ---- can be given a list of message numbers as arguments to apply to a number of messages at once. Thus ! .Ic delete 1 2 deletes messages 1 and 2, while ! .Ic delete 1\-5 deletes messages 1 through 5. The special name ! .Dq \&* ! addresses all messages and ! .Dq \&$ addresses the last message; thus the command .Ic top which prints the first few lines of a message could be used in ! .Ic top \&* to print the first few lines of all messages. .Pp ! .Ss Replying to or originating mail You can use the .Ic reply command to *************** *** 223,237 **** defines the contents of the message. While you are composing a message, .Nm mail ! treats lines beginning with the character ! .Ql Ic \&~ ! specially. For instance, typing ! .Ql Ic \&~m (alone on a line) will place a copy ! of the current message into the response right shifting it by a tabstop ! (see ! .Em indentprefix variable, below). Other escapes will set up subject fields, add and delete recipients to the message and allow you to escape to an editor to revise the --- 224,238 ---- defines the contents of the message. While you are composing a message, .Nm mail ! treats lines beginning with the tilde ! .Pq Sq ~ ! character specially. For instance, typing ! .Ic ~m (alone on a line) will place a copy ! of the current message into the response, right shifting it by a single ! tab-stop (see ! .Va indentprefix variable, below). Other escapes will set up subject fields, add and delete recipients to the message and allow you to escape to an editor to revise the *************** *** 239,245 **** (These options are given in the summary below.) .Pp ! .Ss Ending a mail processing session. You can end a .Nm mail session with the --- 240,246 ---- (These options are given in the summary below.) .Pp ! .Ss Ending a mail processing session You can end a .Nm mail session with the *************** *** 249,260 **** Messages which have been examined go to your .Ar mbox file unless they have been deleted in which case they are discarded. ! Unexamined messages go back to the post office. ! (See the .Fl f option above). .Pp ! .Ss Personal and systemwide distribution lists. It is also possible to create personal distribution lists so that, for instance, you can send mail to .Dq Li cohorts --- 250,260 ---- Messages which have been examined go to your .Ar mbox file unless they have been deleted in which case they are discarded. ! Unexamined messages go back to the post office (see the .Fl f option above). .Pp ! .Ss Personal and system wide distribution lists It is also possible to create personal distribution lists so that, for instance, you can send mail to .Dq Li cohorts *************** *** 270,293 **** The current list of such aliases can be displayed with the .Ic alias command in ! .Nm mail . System wide distribution lists can be created by editing .Pa /etc/aliases , ! see ! .Xr aliases 5 and ! .Xr sendmail 8 ; these are kept in a different syntax. In mail you send, personal aliases will be expanded in mail sent to others so that they will be able to .Ic reply to the recipients. ! System wide ! .Ic aliases are not expanded when the mail is sent, but any reply returned to the machine will have the system wide alias expanded as all mail goes through ! .Xr sendmail . .Pp .Ss Network mail (ARPA, UUCP, Berknet) See --- 270,292 ---- The current list of such aliases can be displayed with the .Ic alias command in ! .Nm mail . System wide distribution lists can be created by editing .Pa /etc/aliases , ! (see ! .Xr aliases 5 and ! .Xr sendmail 8 ) ; these are kept in a different syntax. In mail you send, personal aliases will be expanded in mail sent to others so that they will be able to .Ic reply to the recipients. ! System wide aliases are not expanded when the mail is sent, but any reply returned to the machine will have the system wide alias expanded as all mail goes through ! .Xr sendmail . .Pp .Ss Network mail (ARPA, UUCP, Berknet) See *************** *** 304,315 **** feature. (These options are summarized below.) .Sh SUMMARY ! (Adapted from the `Mail Reference Manual') .Pp Each command is typed on a line by itself, and may take arguments following the command word. The command need not be typed in its ! entirety \- the first command which matches the typed prefix is used. For commands which take message lists as arguments, if no message list is given, then the next message forward which satisfies the command's requirements is used. --- 303,315 ---- feature. (These options are summarized below.) .Sh SUMMARY ! (Adapted from the ! .Dq Mail Reference Manual . ) .Pp Each command is typed on a line by itself, and may take arguments following the command word. The command need not be typed in its ! entirety -- the first command which matches the typed prefix is used. For commands which take message lists as arguments, if no message list is given, then the next message forward which satisfies the command's requirements is used. *************** *** 326,334 **** Print out the preceding message. If given a numeric argument ! .Ar n , goes to the ! .Ar n Ns 'th previous message and prints it. .It Ic \&? Prints a brief summary of commands. --- 326,334 ---- Print out the preceding message. If given a numeric argument ! .Ar n , goes to the ! .Ar n Ns th previous message and prints it. .It Ic \&? Prints a brief summary of commands. *************** *** 403,409 **** .Pq Ic d Takes a list of messages as argument and marks them all as deleted. Deleted messages will not be saved in ! .Ar mbox , nor will they be available for most other commands. .It Ic dp (also --- 403,409 ---- .Pq Ic d Takes a list of messages as argument and marks them all as deleted. Deleted messages will not be saved in ! .Ar mbox , nor will they be available for most other commands. .It Ic dp (also *************** *** 426,436 **** modifying the user's system mailbox, his .Ar mbox file, or his edit file in ! .Fl f . .It Ic file .Pq Ic fi The same as ! .Ic folder . .It Ic folders List the names of the folders in your folder directory. .It Ic folder --- 426,436 ---- modifying the user's system mailbox, his .Ar mbox file, or his edit file in ! .Fl f . .It Ic file .Pq Ic fi The same as ! .Ic folder . .It Ic folders List the names of the folders in your folder directory. .It Ic folder *************** *** 460,473 **** Lists the current range of headers, which is an 18\-message group. If a ! .Ql \&+ ! argument is given, then the next 18\-message group is printed, and if a ! .Ql \&\- argument is given, the previous 18\-message group is printed. .It Ic help A synonym for ! .Ic \&? . .ne li .It Ic hold .Pf ( Ic ho , --- 460,473 ---- Lists the current range of headers, which is an 18\-message group. If a ! .Dq \&+ ! argument is given, the next 18\-message group is printed; if a ! .Dq \&\- argument is given, the previous 18\-message group is printed. .It Ic help A synonym for ! .Ic \&? . .ne li .It Ic hold .Pf ( Ic ho , *************** *** 476,482 **** Takes a message list and marks each message therein to be saved in the user's system mailbox instead of in ! .Ar mbox . Does not override the .Ic delete command. --- 476,482 ---- Takes a message list and marks each message therein to be saved in the user's system mailbox instead of in ! .Ar mbox . Does not override the .Ic delete command. *************** *** 533,539 **** .It Ic preserve .Pq Ic pre A synonym for ! .Ic hold . .It Ic print .Pq Ic p Takes a message list and types out each message on the user's terminal. --- 533,539 ---- .It Ic preserve .Pq Ic pre A synonym for ! .Ic hold . .It Ic print .Pq Ic p Takes a message list and types out each message on the user's terminal. *************** *** 568,577 **** The default message must not be deleted. .It Ic respond A synonym for ! .Ic reply . .It Ic retain Add the list of header fields named to the ! .Ar retained list . Only the header fields in the retain list are shown on your terminal when you print a message. All other header fields are suppressed. --- 568,577 ---- The default message must not be deleted. .It Ic respond A synonym for ! .Ic reply . .It Ic retain Add the list of header fields named to the ! .Ar retained list . Only the header fields in the retain list are shown on your terminal when you print a message. All other header fields are suppressed. *************** *** 601,607 **** .Ar option . Quotation marks may be placed around any part of the assignment statement to quote blanks or tabs, i.e. ! .Dq Li "set indentprefix=\*q->\*q" .It Ic saveignore .Ic Saveignore is to --- 601,607 ---- .Ar option . Quotation marks may be placed around any part of the assignment statement to quote blanks or tabs, i.e. ! .Dq Li "set indentprefix=\*q->\*q" . .It Ic saveignore .Ic Saveignore is to *************** *** 611,622 **** is to .Ic print and ! .Ic type . Header fields thus marked are filtered out when saving a message by .Ic save or when automatically saving to ! .Ar mbox . .pl +1 .It Ic saveretain .Ic Saveretain --- 611,622 ---- is to .Ic print and ! .Ic type . Header fields thus marked are filtered out when saving a message by .Ic save or when automatically saving to ! .Ar mbox . .pl +1 .It Ic saveretain .Ic Saveretain *************** *** 627,641 **** is to .Ic print and ! .Ic type . Header fields thus marked are the only ones saved with a message when saving by .Ic save or when automatically saving to ! .Ar mbox . .Ic Saveretain overrides ! .Ic saveignore . .It Ic shell .Pq Ic sh Invokes an interactive version of the shell. --- 627,641 ---- is to .Ic print and ! .Ic type . Header fields thus marked are the only ones saved with a message when saving by .Ic save or when automatically saving to ! .Ar mbox . .Ic Saveretain overrides ! .Ic saveignore . .It Ic shell .Pq Ic sh Invokes an interactive version of the shell. *************** *** 656,662 **** .It Ic type .Pq Ic t A synonym for ! .Ic print . .It Ic unalias Takes a list of names defined by .Ic alias --- 656,662 ---- .It Ic type .Pq Ic t A synonym for ! .Ic print . .It Ic unalias Takes a list of names defined by .Ic alias *************** *** 676,689 **** .It Ic unset Takes a list of option names and discards their remembered values; the inverse of ! .Ic set . .It Ic visual .Pq Ic v Takes a message list and invokes the display editor on each message. .It Ic write .Pq Ic w Similar to ! .Ic save , except that .Ic only the message body --- 676,689 ---- .It Ic unset Takes a list of option names and discards their remembered values; the inverse of ! .Ic set . .It Ic visual .Pq Ic v Takes a message list and invokes the display editor on each message. .It Ic write .Pq Ic w Similar to ! .Ic save , except that .Ic only the message body *************** *** 696,702 **** .It Ic xit .Pq Ic x A synonym for ! .Ic exit . .It Ic z .Nm mail presents message headers in windowfuls as described under the --- 696,702 ---- .It Ic xit .Pq Ic x A synonym for ! .Ic exit . .It Ic z .Nm mail presents message headers in windowfuls as described under the *************** *** 708,723 **** .Ic \&z command. Also, you can move to the previous window by using ! .Ic \&z\&\- . .El ! .Ss Tilde/Escapes Here is a summary of the tilde escapes, which are used when composing messages to perform special functions. Tilde escapes are only recognized at the beginning of lines. The name ! .Dq Em tilde\ escape is somewhat of a misnomer since the actual escape character can be set by the option .Ic escape . --- 708,723 ---- .Ic \&z command. Also, you can move to the previous window by using ! .Ic \&z\&\- . .El ! .Ss Tilde/escapes Here is a summary of the tilde escapes, which are used when composing messages to perform special functions. Tilde escapes are only recognized at the beginning of lines. The name ! .Dq tilde escape is somewhat of a misnomer since the actual escape character can be set by the option .Ic escape . *************** *** 731,737 **** Add the given names to the list of carbon copy recipients. .It Ic \&~d Read the file ! .Dq Pa dead.letter from your home directory into the message. .It Ic \&~e Invoke the text editor on the message collected so far. --- 731,737 ---- Add the given names to the list of carbon copy recipients. .It Ic \&~d Read the file ! .Pa dead.letter from your home directory into the message. .It Ic \&~e Invoke the text editor on the message collected so far. *************** *** 758,764 **** .It Ic \&~m Ns Ar messages Read the named messages into the message being sent, indented by a tab or by the value of ! .Ar indentprefix . If no messages are specified, read the current message. Message headers currently being ignored (by the --- 758,764 ---- .It Ic \&~m Ns Ar messages Read the named messages into the message being sent, indented by a tab or by the value of ! .Ar indentprefix . If no messages are specified, read the current message. Message headers currently being ignored (by the *************** *** 775,781 **** fields. .It Ic \&~q Abort the message being sent, copying the message to ! .Dq Pa dead.letter in your home directory if .Ic save is set. --- 775,781 ---- fields. .It Ic \&~q Abort the message being sent, copying the message to ! .Pa dead.letter in your home directory if .Ic save is set. *************** *** 815,821 **** you have changed the escape character, then you should double that character in order to send it. .El ! .Ss Mail Options Options are controlled via .Ic set and --- 815,821 ---- you have changed the escape character, then you should double that character in order to send it. .El ! .Ss Mail options Options are controlled via .Ic set and *************** *** 870,876 **** on the command line and causes .Nm mail to output all sorts of information useful for debugging ! .Nm mail . .It Ar dot The binary option .Ar dot --- 870,876 ---- on the command line and causes .Nm mail to output all sorts of information useful for debugging ! .Nm mail . .It Ar dot The binary option .Ar dot *************** *** 913,919 **** (erase or delete) .Nm mail copies the partial letter to the file ! .Dq Pa dead.letter in your home directory. Setting the binary option .Ar nosave --- 913,919 ---- (erase or delete) .Nm mail copies the partial letter to the file ! .Pa dead.letter in your home directory. Setting the binary option .Ar nosave *************** *** 927,942 **** .It Ar quiet Suppresses the printing of the version when first invoked. .It Ar searchheaders ! If this option is set, then a message-list specifier in the form ``/x:y'' ! will expand to all messages containing the substring ``y'' in the header ! field ``x''. The string search is case insensitive. ! If ``x'' is omitted, it will default to the ``Subject'' header field. ! The form ``/to:y'' is a special case, and will expand ! to all messages containing the substring ``y'' in the ``To'', ``Cc'' ! or ``Bcc'' header fields. ! The check for "to" is case sensitive, so that ! ``/To:y'' can be used to limit the search for ``y'' to just ! the ``To:'' field. .It Ar verbose Setting the option .Ar verbose --- 927,964 ---- .It Ar quiet Suppresses the printing of the version when first invoked. .It Ar searchheaders ! If this option is set, then a message-list specifier in the form ! .Dq /x:y ! will expand to all messages containing the substring ! .Dq y ! in the header ! field ! .Dq x . ! The string search is case insensitive. If ! .Dq x ! is omitted, it will default to the ! .Dq Subject ! header field. ! The form ! .Dq /to:y ! is a special case, and will expand ! to all messages containing the substring ! .Dq y ! in the ! .Dq To , ! .Dq Cc ! or ! .Dq Bcc ! header fields. ! The check for ! .Dq to ! is case sensitive, so that ! .Dq /To:y ! can be used to limit the search for ! .Dq y ! to just the ! .Dq To: ! field. .It Ar verbose Setting the option .Ar verbose *************** *** 947,953 **** the actual delivery of messages is displayed on the user's terminal. .El ! .Ss Option String Values .Bl -tag -width Va .It Ev EDITOR Pathname of the text editor to use in the --- 969,975 ---- the actual delivery of messages is displayed on the user's terminal. .El ! .Ss Option string values .Bl -tag -width Va .It Ev EDITOR Pathname of the text editor to use in the *************** *** 1005,1011 **** .It Ar folder The name of the directory to use for storing folders of messages. ! If this name begins with a `/', .Nm mail considers it to be an absolute pathname; otherwise, the folder directory is found relative to your home directory. --- 1027,1034 ---- .It Ar folder The name of the directory to use for storing folders of messages. ! If this name begins with a ! .Dq / , .Nm mail considers it to be an absolute pathname; otherwise, the folder directory is found relative to your home directory. *************** *** 1022,1029 **** mail. If not defined, then outgoing mail is not so saved. .It Ar indentprefix ! String used by the ``~m'' tilde escape for indenting messages, in place of ! the normal tab character (^I). Be sure to quote the value if it contains spaces or tabs. .It Ar toplines --- 1045,1054 ---- mail. If not defined, then outgoing mail is not so saved. .It Ar indentprefix ! String used by the ! .Ic \&~m ! tilde escape for indenting messages, in place of the normal tab character ! .Pq Sq ^I Be sure to quote the value if it contains spaces or tabs. .It Ar toplines *************** *** 1048,1069 **** .Sh FILES .Bl -tag -width /usr/share/misc/mail.*help -compact .It Pa /var/mail/* ! Post office (unless overridden by the .Ev MAIL ! environment variable). .It ~/mbox ! User's old mail. .It ~/.mailrc ! File giving initial mail commands. ! This can be overridden by setting the .Ev MAILRC ! environment variable. .It Pa /tmp/R* ! Temporary files. .It Pa /usr/share/misc/mail.*help ! Help files. .It Pa /etc/mail.rc ! System initialization file. .El .Sh SEE ALSO .Xr fmt 1 , --- 1073,1093 ---- .Sh FILES .Bl -tag -width /usr/share/misc/mail.*help -compact .It Pa /var/mail/* ! post office (unless overridden by the .Ev MAIL ! environment variable) .It ~/mbox ! user's old mail .It ~/.mailrc ! file giving initial mail commands; can be overridden by setting the .Ev MAILRC ! environment variable .It Pa /tmp/R* ! temporary files .It Pa /usr/share/misc/mail.*help ! help files .It Pa /etc/mail.rc ! system initialization file .El .Sh SEE ALSO .Xr fmt 1 , *************** *** 1074,1082 **** .Xr mailaddr 7 , .Xr mail.local 8 , .Xr sendmail 8 - and .Rs ! .%T "The Mail Reference Manual" . .Re .Sh HISTORY A --- 1098,1105 ---- .Xr mailaddr 7 , .Xr mail.local 8 , .Xr sendmail 8 .Rs ! .%T "The Mail Reference Manual" .Re .Sh HISTORY A *************** *** 1097,1101 **** and .Nm mailx are just links to ! .Nm Mail , which can be confusing. --- 1120,1124 ---- and .Nm mailx are just links to ! .Nm Mail , which can be confusing.