4.3BSD-UWisc/man/cat1/msgs.1

Compare this file to the similar file:
Show the results in this format:




MSGS(1)             UNIX Programmer's Manual              MSGS(1)



NAME
     msgs - system messages and junk mail program

SYNOPSIS
     msgs [ -fhlpq ] [ number ] [ -number ]

     msgs -s

     msgs -c [ -days ]

DESCRIPTION
     _M_s_g_s is used to read system messages.  These messages are
     sent by mailing to the login `msgs' and should be short
     pieces of information which are suitable to be read once by
     most users of the system.

     _M_s_g_s is normally invoked each time you login, by placing it
     in the file ._l_o_g_i_n (._p_r_o_f_i_l_e if you use /_b_i_n/_s_h).  It will
     then prompt you with the source and subject of each new mes-
     sage.  If there is no subject line, the first few non-blank
     lines of the message will be displayed.  If there is more to
     the message, you will be told how long it is and asked
     whether you wish to see the rest of the message.  The possi-
     ble responses are:

     y      type the rest of the message.

     RETURN synonym for y.

     n      skip this message and go on to the next message.

     -      redisplay the last message.

     q      drops you out of _m_s_g_s; the next time you run the pro-
            gram it will pick up where you left off.

     s      append the current message to the file ``Messages''
            in the current directory; `s-' will save the previ-
            ously displayed message. A `s' or `s-' may be fol-
            lowed by a space and a file name to receive the mes-
            sage replacing the default ``Messages''.

     m      or `m-' causes a copy of the specified message to be
            placed in a temporary mailbox and _m_a_i_l(1) to be
            invoked on that mailbox.  Both `m' and `s' accept a
            numeric argument in place of the `-'.

     _M_s_g_s keeps track of the next message you will see by a
     number in the file ._m_s_g_s_r_c in your home directory.  In the
     directory /_u_s_r/_s_p_o_o_l/_m_s_g_s it keeps a set of files whose
     names are the (sequential) numbers of the messages they
     represent.  The file /_u_s_r/_s_p_o_o_l/_m_s_g_s/_b_o_u_n_d_s shows the low



Printed 12/27/86           May 9, 1986                          1






MSGS(1)             UNIX Programmer's Manual              MSGS(1)



     and high number of the messages in the directory so that
     _m_s_g_s can quickly determine if there are no messages for you.
     If the contents of _b_o_u_n_d_s is incorrect it can be fixed by
     removing it; _m_s_g_s will make a new _b_o_u_n_d_s file the next time
     it is run.

     The -s option is used for setting up the posting of mes-
     sages.  The line

          msgs: "| /usr/ucb/msgs -s"

     should be include in /_u_s_r/_l_i_b/_a_l_i_a_s_e_s to enable posting of
     messages.

     The -c option is used for performing cleanup on /_u_s_r/_m_s_g_s.
     An entry with the -c option should be placed in
     /_u_s_r/_l_i_b/_c_r_o_n_t_a_b to run every night.  This will remove all
     messages over 21 days old.  A different expiration may be
     specified on the command line to override the default.

     Options when reading messages include:

     -f     which causes it not to say ``No new messages.''.
            This is useful in your ._l_o_g_i_n file since this is
            often the case here.

     -q     Queries whether there are messages, printing ``There
            are new messages.'' if there are.  The command ``msgs
            -q'' is often used in login scripts.

     -h     causes _m_s_g_s to print the first part of messages only.

     -l     option causes only locally originated messages to be
            reported.

     _n_u_m    A message number can be given on the command line,
            causing _m_s_g_s to start at the specified message rather
            than at the next message indicated by your ._m_s_g_s_r_c
            file.  Thus

                msgs -h 1

            prints the first part of all messages.

     -_n_u_m_b_e_r
            will cause _m_s_g_s to start _n_u_m_b_e_r messages back from
            the one indicated by your ._m_s_g_s_r_c file, useful for
            reviews of recent messages.

     -p     causes long messages to be piped through _m_o_r_e(1).





Printed 12/27/86           May 9, 1986                          2






MSGS(1)             UNIX Programmer's Manual              MSGS(1)



     Within _m_s_g_s you can also go to any specific message by typ-
     ing its number when _m_s_g_s requests input as to what to do.

POSTING MESSAGES
     A number of aliases are provided at Wisconsin to make it
     easy to send messages to groups of systems that receive mes-
     sages.  Following is a list of these aliases and a descrip-
     tion of the systems that receive these aliases.  To post a
     message, just use the aliases below to select the group of
     people that you want the message to go to.

     msgs           Sends to the posting machine _o_n_l_y

     msgs-research  Sends to all Computer Science Dept. research
                    systems

     msgs-instruct  Sends to all Computer Science Dept. instruc-
                    tional systems

     msgs-cs        Sends to all Computer Science Dept. systems

     msgs-stat      Sends to all Statistics Dept. systems

     msgs-all       Sends to all of the above

FILES
     /usr/spool/msgs/*   database
     ~/.msgsrc           number of next message to be presented

AUTHORS
     William Joy
     David Wasley

SEE ALSO
     aliases(5), crontab(5), mail(1), more(1)

LOCAL MODS
     Added the various aliases which allow posting messages to
     different groups of people.  Changed the directory that con-
     tains the messages from /usr/msgs to /usr/spool/msgs.

BUGS










Printed 12/27/86           May 9, 1986                          3