BSD 3 development
[unix-history] / usr / doc / mail / mail6.nr
CommitLineData
096f524c
KS
1.sh 1 "Additional commands"
2.pp
3This section describes additional Mail commands available when
4receiving mail.
5.pp
6The
7.b next
8command goes to the next message and types it. If given a message list,
9.b next
10goes to the first such message and types it. Thus,
11.(l
12type root
13.)l
14goes to the next message sent by \*(lqroot\*(rq and types it.
15The
16.b next
17command can be abbreviated to simply a newline, which means that one
18can go to and type a message by simply giving its message number or
19one of the magic characters
20.q "\(ua"
21.q "."
22or
23.q "$".
24Thus,
25.(l
26\&.
27.)l
28prints the current message and
29.(l
304
31.)l
32prints message 4.
33.pp
34The
35.rb \-
36command goes to the previous message and prints it. The
37.rb \-
38command may be given a decimal number
39.i n
40as an argument, in which case the
41.i n th
42previous message is gone to and printed.
43.pp
44The
45.b save
46command allows you to save messages received from others on a file
47other than
48.i mbox.
49Its syntax varies somewhat from the other commands which accept
50a message list in that the final word on the command line is taken to be
51the file on which to save the messages. The named messages are
52appended to the file (which is created if it did not already exist)
53and are marked as saved. Saved messages are not automatically saved in
54.i mbox
55at quit time, nor are they selected by the
56.b next
57command described above, unless explicitly specified. The
58.b save
59command provides a facility for saving messages pertaining to a particular
60subject or from a particular person in a special place.
61.pp
62The
63.b undelete
64command causes a message which had been deleted previously to regain
65its initial status. Only messages which are already deleted may be
66undeleted. This command may be abbreviated to
67.b u .
68.pp
69The
70.b preserve
71command takes a message list and marks each message therein so that it
72will be saved in your system mailbox instead of being deleted or
73saved in
74.i mbox
75when you quit. This is useful for saving messages of importance that
76you want to see again, or messages not intended for you if you are sharing
77a login name.
78.pp
79Often, one wants to deal with a message by responding to its author right
80then and there. The
81.b reply
82command is useful for this purpose: it takes a message list and sends mail
83to the authors of those messages. The message is collected in the usual
84fashion by reading up to an EOT. All of the tilde escapes described in section
85three will work in
86.b reply .
87Additionally, if there are header fields
88in the message being replied to, this information is copied into the
89new message. The
90.b reply
91command can be abbreviated to
92.b r .
93.pp
94In order to simply mail to a user inside of Mail, the
95.b mail
96command is provided. This sends mail in the manner described for the
97.b reply
98command above, except that the user supplies a list of recipient login
99names and distribution groups. All of the tilde escapes described in
100section three will work in
101.b mail .
102The
103.b mail
104command may be abbreviated to
105.b m .
106.pp
107In order to edit individual messages using the text editor, the
108.b edit
109command is provided. The
110.b edit
111command takes a list of message as described under the
112.b type
113command and processes each by writing it into the file
114Message\c
115.i x
116where
117.i x
118is the message number being edited and executing the text editor on it.
119When you have edited the message to your satisfaction, write the message
120out and quit, upon which Mail will read the message back and remove the file.
121.b Edit
122may be abbreviated to
123.b e .
124.pp
125It is often useful to be able to invoke one of two editors,
126based on the type of terminal one is using. To invoke
127a display oriented editor, you can use the
128.b visual
129command. The operation of the
130.b visual
131command is otherwise identical to that of the
132.b edit
133command.
134.pp
135When Mail is invoked to receive mail, it prints out the message header
136for each message. In order to reprint the headers for remaining messages
137(those which haven't been deleted), you may type the
138.b headers
139command. Deleted messages do not appear in the listing, saved messages are
140flagged with a
141.q "*"
142and preserved messages are flagged with a
143\*(lqP.\*(rq
144.pp
145The
146.b from
147command takes a list of messages and prints out the header lines for each one;
148hence
149.(l
150from joe
151.)l
152is the easy way to display all the message headers from \*(lqjoe.\*(rq
153.pp
154The
155.b top
156command takes a message list and prints the first five lines
157of each addressed message. It may be abbreviated to
158.b to .
159.pp
160The
161.b dt
162command deletes the current message and prints the next message.
163It is useful for quickly reading and disposing of mail.