mail.1
来自「<B>Digital的Unix操作系统VAX 4.2源码</B>」· 1 代码 · 共 894 行 · 第 1/2 页
1
894 行
.TH mail 1.SH Namemail \- send or read mail.SH Syntax.B mail[\fB\-v\fR] [\fB\-i\fR] [\fB\-n\fR] [\fB\-e\fR] [\fB\-s\fI subject\fR\|] [\|\fIuser...\fR].br.B mail[\fB\-v\fR] [\fB\-i\fR] [\fB\-n\fR] \fB\-f\fR [\|\fIname\fR\|].br.B mail[\fB\-v\fR] [\fB\-i\fR] [\fB\-n\fR] \fB\-u\fI user\fR.br.B mail nodename::username (If DECnet is installed.).SH Description .NXR "mail program".NXR "mail" "sending".NXA "mail program" "write command".NXA "mail program" "talk program"The.PN mailutility is an intelligent mail processing system which hasa command syntax similar to.PN ed .However, in .PN maillines are replaced by messages..PPIf DECnet is installed on your system, you can also send and receivemail from other DECnet users. See .MS mailaddr 7for information on DECnet addressing..PP.I "Sending mail.\ "To send a message to one or more persons, type.PN mailand the names of the peoplereceiving your mail. Press the RETURNkey. Note that if you use other arguments, the names of the recipients shouldalways be the last element on the command line.For example,.EXmail \-v \-s "mail message" \fIusers\fP.EEIf you do not specify a subject on the command line,you are prompted for a subject.After entering a subject, and pressing the RETURN key, type your message.To send the message, type a period (\&.) orCTRL Dat the beginning of a new line..PPYou can use tilde (\~) escape sequences to performspecial functions when composing mail messages. Seethe list of options for more on tilde escape sequences..PP.I "Reading mail.\ ".NXR "mail" "reading"In normal usage.PN mailis given no arguments and checks your mail out of themail directory. Then itprints out a one line header of each message there.The current message is initially the first message and is numbered 1. Itcan be displayed using the.PN print. (p)command..PPThe .PN \-eoption causes mail not to be printed. Instead,an exit valueis returned. For the exit status, see RETURN VALUES..NXR "mail" "printing".NXR "print command (mail)"You can move among the messages bytyping a plus sign (+) followed by a number to move forwardthat many messages, or a minus sign (\-) followed by a number tomove backward that many messages..PP.I "Disposing of mail.\ ".NXR "mail" "deleting".NXR "mail" "undeleting"After reading a message you candelete (d)it or reply (r)to it.Deleted messages can be undeleted,however, in one of two ways: you can use the undelete (u) commandand the numberof the message, or you can end the mail session withthe exit (x) command.Note that if you end a session with the quit (q)command, you cannot retrieve deleted messages..PP.I "Specifying messages.\ ".NXR "mail" "specifying messages"Commands such as.PN printand.PN deletecan be given a list of message numbers as arguments.Thus, the command.EXdelete 1 2 .EEdeletes messages 1 and 2, while the command.EXdelete 1\-5.EEdeletes messages 1 through 5.The asterisk (*) addresses all messages, and the dollar sign ($) addressesthe last message. For example, the.PN topcommand, which prints the first few lines of amessage, can be used in the following mannerto print the first few lines of all messages:.EXtop *.EE.PP.I "Replying to or originating mail.\ ".NXR "mail" "replying to"Use the.PN replycommand torespond to a message..PP.I "Ending a mail processing session.\ ".NXR "mail" "ending a session"End a.PN mailsession with the.PN quit(q) command.Unless they were deleted, messages thatyou have read go to your.I mboxfile.Unread messages go back to the mail directory. The \-f option causes.PN mailto read in the contents of your.I mbox(or the specified file)for processing. When you.PN quit ,the mail utilitywrites undeleted messages back to this file.The \-u flag is a short way of specifying:.PN mail .PN \-f.PN /usr/spool/mail/user ..PP.I "Personal and systemwide distribution lists.\ ".NXR "mail" "creating a distribution list"You can create a personal distribution list thatdirects mail to a group of people.Such lists can be defined by placing a line similar to the following in the \&.mailrc file in your home directory:.EXalias cohorts bill ozalp jkf mark kridle@ucbcory.EE.PPCohorts is the name of the distribution list thatconsists of the following users:bill, ozalp, jkf, mark, and kridle@ucbcory.A list of current aliases can be displayed with the.PN alias.PN (a)command in.PN mail ..PPSystem wide distribution lists can be created by editing.PN /usr/lib/aliases .The syntax of system wide lists differsfrom that of personally defined aliases..PPPersonal aliases are expanded in mail you send.When a recipient on a personallydefined mailing list uses the.PN reply.PN (r)option, the entire mailing list receives the responseautomatically.System wide \fIaliases\fR are not expanded when the mail is sent,but any reply returned to the machine will have the system-widealias expanded as all mail goes through.PN sendmail ..PPForwarding is also a form of aliasing.A .PN \&.forward file can be set up in a user's home directory.Mail for that user is then redirected to the list of addresses inthe .PN \&.forward file.See.MS aliases 5and .MS sendmail 8 for more information..PP.I "Network mail (ARPA, UUCP, Berknet, DECnet)\ "See .MS mailaddr 7for a description of network addresses..SH Options.NXR "mail program" "flags".TP\fB\-e\fRCauses.PN mailnot to be printed. Instead, an exit valueis returned. .TP\fB\-f\fRCauses .PN mailto read in the contents of your.I mboxfile (or another file you specify) for processing..TP\fB\-i\fRCauses tty interrupt signals to be ignored. This isuseful when using.PN mailon noisy phone lines..TP\fB\-n\fRInhibits the reading of /usr/lib/Mail.rc..TP\fB\-s\fRSpecifies a subject on the command line.Note that only the first argument after the\-s flag is used as a subject and that you must enclose subjectscontaining spaces in quotes..TP\fB\-u\fRSpecifies a short hand for expressing the following:.EXmail \-f /usr/spool/mail/user .EE.TP\fB\-v\fRPrints the mail message. The details ofdelivery are displayed on the user's terminal..PPThefollowing options can be set in the .mailrcfile to alter the behavior of the.PN mailcommand..NXR "mail program" "command list".PPEach command is typed on a line by itself and may take argumentsfollowing the command word and the command abbreviation. For commands that take message lists as arguments, if no messagelist is given, then the next message forward which satisfies thecommand's requirements is used. If there are no messages forward ofthe current message, the search proceeds backwards. If there are nogood messages at all,.PN mailcancels the command,displaying the message: No applicable messages..TP 12n.B \-Prints out the previous message. If given a numericargument.IR n,prints.IR n \-thprevious message. .TP.B ?Prints a brief summary of commands..TP.B !Executes the \s-2ULTRIX\s0 shell command which follows..TP\fBalias\fR (\fBa\fR).NXR "alias command (mail)"Prints out all currently-defined aliases, if givenwithout arguments. With oneargument, prints out that alias. With more than one argument, createsa new or changes an old alias.These aliases are in effect for the current mail session only..TP\fBalternates\fR (\fBalt\fR).NXR "alternates command (mail)"Informs.PN mailthat you have several valid addresses.The.PN alternatescommand is useful if you have accounts on more than one machine.When you.PN replyto messages,.PN maildoes not send a copy of the message to any of the addresseslisted on the.I alternateslist. If the.PN alternatescommand is given with no argument, the current set of alternatenames is displayed..TP\fBchdir\fR (\fBch\fR).NXR "chdir command (mail)"Changes the user's working directory to that specified.If no directory is given, then the.PN chdircommand changes to the user's login directory..TP\fBcopy\fR (\fBco\fR).NXR "copy command (mail)"Takes a message list and file name and appends each messageto the end of the file. The.PN copycommand functions in the same way as the.PN save command, except that it does not mark the messages that youcopy for deletion when you quit..TP\fBdelete\fR (\fBd\fR).NXR "delete command (mail)"Takes a list of messages as argument and marks them all as deleted.Deleted messages are not saved in.IR mbox ,nor are they available for most other commands. .TP\fBdp\fR (or \fBdt\fR).NXR "dp command (mail)"Deletes the current message and prints the next message.If there is no next message, .PN mailreturns a message: at EOF..TP\fBedit\fR (\fBe\fR).NXR "edit command (mail)"Takes a list of messages and points the text editor at each one inturn. On return from the editor, the message is read back in..TP\fBexit\fR (\fBex\fR or \fBx\fR).NXR "exit command (mail)"Returns to the Shell withoutmodifying the user's system mailbox,.I mboxfile, or edit file in.PN \-f ..TP\fBfile\fR (\fBfi\fR).NXR "file command (mail)"Switches to a new mail file or folder. If noarguments are given, it tells you which file you are currently reading.If you give it an argument, it writes out changes (suchas deletions) you have made in the current file and reads inthe new file. Some special conventions are recognized forthe name. A pound sign (#) indicates the previous file, a percent sign (%) indicates your systembmailbox, %user indicates the user's system mailbox, anampersand (&) indicatesyour \~/mbox file, and +folder indicates a file in your folderdirectory..TP.B folders.NXR "folders command (mail)"List the names of the folders in your folder directory..TP\fBfolder\fR (\fBfo\fR).NXR "folder command (mail)"Switches to a new mail file or folder. The .PN foldercommand functions in the same way as the .PN file command..TP\fBfrom\fR (\fBf\fR).NXR "from command (mail)".NXA "type command (mail)" "print command (mail)".NXA "copy command (mail)" "save command (mail)".NXA "file command (mail)" "folder command (mail)"Takes a list of messages and prints their message headersin the order that they appear in the mail directory, not in theorder given in the list..TP\fBheaders\fR (\fBh\fR).NXR "headers command (mail)"Lists the current range of headers, which is a 20 message group. Ifa plus sign (+) is given as an argument, then the nextmessage group is printed. Ifa minus sign (\-) is given as an argument, the previousmessage group is printed..TP.B help.NXR "help command (mail)"Prints a brief summary of commands. Synonymous with ?..TP\fBhold\fR (\fBho\fR, also \fBpreserve\fR).NXR "hold command (mail)"Takes a message list and marks eachmessage in it to be saved in theuser's system mailbox instead of in.IR mbox.The .PN holdcommand does not override the.B deletecommand..TP.B ignore.NXR "ignore command (mail)"Adds the list of header fields named to the.IR "ignored list" .Header fields in the ignore list are not printedon your terminal when you print a message. Thiscommand is frequently used to suppress certain machine-generatedheader fields. The.PN typeand.PN printcommands are used to print a message in its entirety, includingignored fields. If.PN ignoreis executed with no arguments, it lists the current set ofignored fields..TP\fBmail\fR (\fBm\fR).NXR "mail command (mail)"Takes login names and distribution group namesas arguments and sendsmail to those people..TP\fBmbox\fRIndicates that a list of messages should be sent to .I mbox
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?