BSD 4_1_snap development
[unix-history] / usr / man / man1 / msgs.1
CommitLineData
e3758c96
C
1.TH MSGS 1
2.UC 4
3.SH NAME
4msgs \- system messages and junk mail program
5.SH SYNOPSIS
6.B msgs
7[
8.B \-fhlpq
9] [
10number
11] [
12\-number
13]
14.SH DESCRIPTION
15.I Msgs
16is used to read system messages.
17These messages are
18sent by mailing to the login `msgs' and should be short
19pieces of information which are suitable to be read once by most users
20of the system.
21.PP
22.I Msgs
23is normally invoked each time you login, by placing it in the file
24.I \&.login
25.I (\&.profile
26if you use
27.IR /bin/sh ).
28It will then prompt you with the source and subject of each new message.
29If there is no subject line, the first few non-blank lines of the
30message will be displayed.
31If there is more to the message, you will be told how
32long it is and asked whether you wish to see the rest of the message.
33The possible responses are:
34.TP 7
35.B y
36type the rest of the message
37.TP 7
38RETURN
39synonym for y.
40.TP 7
41.B n
42skip this message
43and go on to the next message.
44.TP 7
45.B \-
46redisplay the last message.
47.TP 7
48.B q
49drops you out of
50.I msgs;
51the next time you run the program it will pick up where you left off.
52.TP 7
53.B s
54append the current message to the file ``Messages'' in the current directory;
55`s\-' will save the previously displayed message. A `s' or `s\-' may
56be followed by a space and a filename to receive the message replacing
57the default ``Messages''.
58.TP 7
59.B m
60or `m\-' causes a copy of the specified message to be placed in a temporary
61mailbox and
62.IR mail (1)
63to be invoked on that mailbox.
64Both `m' and `s' accept a numeric argument in place of the `\-'.
65.PP
66.I Msgs
67keeps track of the next message you will see by a number in the file
68.I \&.msgsrc
69in your home directory.
70In the directory
71.I /usr/msgs
72it keeps a set of files whose names are the (sequential) numbers
73of the messages they represent.
74The file
75.I /usr/msgs/bounds
76shows the low and high number of the messages in the directory
77so that
78.I msgs
79can quickly determine if there are no messages for you.
80If the contents of
81.I bounds
82is incorrect it can be fixed by removing it;
83.I msgs
84will make a new
85.I bounds
86file the next time it is run.
87.PP
88Options to msgs include:
89.TP 7
90.B \-f
91which causes it not to say ``No new messages.''.
92This is useful in your
93.I \&.login
94file since this is often the case here.
95.TP 7
96.B \-q
97Queries whether there are messages, printing
98``There are new messages.'' if there are.
99The command ``msgs \-q'' is often used in login scripts.
100.TP 7
101.B \-h
102causes
103.I msgs
104to print the first part of messages only.
105.TP 7
106.B \-l
107option causes only locally originated messages to be reported.
108.TP 7
109\fInum\fR
110A message number can be given
111on the command line, causing
112.I msgs
113to start at the specified message rather than at the next message
114indicated by your
115.I \&.msgsrc
116file.
117Thus
118.IP "" 7
119 msgs \-h 1
120.IP "" 7
121prints the first part of all messages.
122.TP 7
123.I "\-number"
124will cause
125.I msgs
126to start
127.I number
128messages back from the one indicated by your
129.I \&.msgsrc
130file, useful for reviews of recent messages.
131.TP 7
132.B \-p
133causes long messages to be piped through
134.IR more (1).
135.PP
136Within
137.I msgs
138you can also go to any specific message by typing its number when
139.I msgs
140requests input as to what to do.
141.SH FILES
142.ta 2i
143/usr/msgs/* database
144.br
145~/.msgsrc number of next message to be presented
146.SH AUTHORS
147William Joy
148.br
149David Wasley
150.SH SEE ALSO
151mail(1), more(1)
152.SH BUGS