


READNEWS(1)              USER COMMANDS                READNEWS(1)



NAME
     readnews - read news articles

SYNOPSIS
     readnews [-n newsgroups] [-i] [-clpC] [-s[-+?  [_g_r_o_u_p]]]

DESCRIPTION
     _R_e_a_d_n_e_w_s without arguments enters command mode, which allows
     printing  of  unread  articles.   This  is the normal way of
     using _r_e_a_d_n_e_w_s.  _R_e_a_d_n_e_w_s maintains a ._n_e_w_s_r_c  file  in  the
     user's  home  directory  that  specifies  all  news articles
     already read.  It is updated at the end of each reading ses-
     sion.   Some  useful functions are available which don't use
     command mode.  The flags for these are:

     -c   Check if there is news,  and  if  so  print  `You  have
          news.'.   A line `readnews -c' is usually placed in the
          system ._p_r_o_f_i_l_e (/etc/profile).

     -C   Check if there is news, and print the groups and number
          of articles in each group to be read.

     -l   List the titles of available news articles.

     -p   Print all  articles  on  standard  output,  and  update
          _n_e_w_s_r_c.

     -s   Print the newsgroup subscription list.

     -s+ _g_r_o_u_p
          Add _g_r_o_u_p to the subscription list.

     -s- _g_r_o_u_p
          Subtract _g_r_o_u_p from the subscription list.

     -s?  List currently active newsgroups.  The remaining  flags
          determine article selection, and may also appear in the
          ._n_e_w_s_r_c file.  Options may be specified in the  ._n_e_w_s_r_c
          file   by   entering   lines  prefixed  with  the  word
          `options', followed by the options arguments.  This  is
          most  useful  with  the  -n  flag, specifying the usual
          groups one wishes to subscribe to.

     -n _n_e_w_s_g_r_o_u_p_s
          Select all articles  belonging  to  _n_e_w_s_g_r_o_u_p_s.   _n_e_w_s_-
          _g_r_o_u_p_s  is  a  comma separated list of newsgroup names.
          The character  `!'  may  be  used  to  exclude  certain
          groups,  and  the  word  `all' can be used to match any
          group.  e.g. `-n all,!net.jokes'

     -i   Ignore ._n_e_w_s_r_c file. It is not read or  updated.   This
          allows  selection  of  articles  that have already been



Sun Release 4.1     Last change: 21 Nov 1990                    1






READNEWS(1)              USER COMMANDS                READNEWS(1)



          read.  Some overall parameters are  set  by  a  control
          file,   _N_E_W_S_C_T_L/_r_e_a_d_n_e_w_s._c_t_l,  which  contains  control
          lines (each a keyword followed by white space  followed
          by  a value) and comments (each starting with `#').  If
          no -n option is specified, either by the  user  or  his
          ._n_e_w_s_r_c file, the value specified on the defsub line of
          the control file is used as the list of  newsgroups  to
          be  presented.   A  single  mandatory  newsgroup may be
          specified as the value of the mustsub control line;  in
          the  absence  of  a  command-line  -n  (not  one from a
          ._n_e_w_s_r_c), that newsgroup is  always  presented  to  the
          user  even  if  he did not ask for it.  Both defsub and
          mustsub default to ``general''.

COMMANDS
     This section details the commands available when _r_e_a_d_n_e_w_s is
     in  command mode (no -clpsC arguments).  The simplest way of
     using this mode, is to  enter  RETURN  after  every  prompt.
     This  will present to the user, a short heading for an arti-
     cle, then a prompt.  Typing  RETURN  again  will  print  the
     article  body.   Typing RETURN yet again will print the next
     heading, and so on.  If having read the heading,  you  don't
     wish  to  read the article, you may type `n' (or `+' or ';')
     which will take you directly to the next heading.  An  arti-
     cle  is treated as having been read, if either you have seen
     the article body, or typed `n' to skip over it.  A number of
     commands  operate on the `current' article.  This is defined
     as the article whose header you  have  most  recently  seen.
     The commands to read news are:

     RETURN
          Either print the current article, or  go  to  the  next
          article and print its header.

     n or + or ;
          Go to the next article and print its header.

     .    Print the current article.

     -    Go back to the previous article. This is a toggle, typ-
          ing it twice returns you to the original article.

     _n_u_m_b_e_r
          Go to the article  _n_u_m_b_e_r  in  the  current  newsgroup.
          Like the `-' command, you always return to the original
          article after reading the selected article.

     s [_f_i_l_e]
          Save the current article, appending it to the specified
          file (default $HOME/articles).

     h    Print the current header (slightly  more  verbose  than



Sun Release 4.1     Last change: 21 Nov 1990                    2






READNEWS(1)              USER COMMANDS                READNEWS(1)



          normal header).

     H    Print the current header in full (very verbose).

     N [_n_e_w_s_g_r_o_u_p]
          Go to the next newsgroup, or  to  the  specified  news-
          group.

     U    Unsubscribe from this newsgroup, and  go  to  the  next
          newsgroup.

     !_c_o_m_m_a_n_d
          Shell escape.  _C_o_m_m_a_n_d is executed.  If _c_o_m_m_a_n_d is  `!'
          the last escape command is executed.

     q or EOT
          Quit.  The ._n_e_w_s_r_c file will be  updated  provided  the
          flag -i was not specified.

     x    Exit.  ._n_e_w_s_r_c is left unchanged (as if no articles had
          been  read).  Some commands are available to send/reply
          or post news articles:

     r    Reply to sender of the current article by mail.   _R_e_a_d_-
          _n_e_w_s  sets  up  the appropriate headers, and then calls
          _m_a_i_l(1) (or $MAILER, if there is  such  an  environment
          variable)  to  send a reply to the sender.  If there is
          no mailvia line in the control  file,  the  address  is
          taken  from  the ``From'' header of the article, and is
          in Internet form.  If the value in the mailvia line  is
          ``<path>'',  the  address  is  taken  from the ``Path''
          header and is in UUCPnet form.  If the value of mailvia
          is  something else, the ``From'' address is transformed
          to  UUCPnet  syntax  (``site.x.y!user''   rather   than
          ``user@site.x.y''),  and the mailvia value is prepended
          to it, with an intervening ``!''.

     f    Post a followup to the current article.  _R_e_a_d_n_e_w_s  sets
          up  the appropriate headers, and then calls _p_o_s_t_n_e_w_s(1)
          to post the followup article.

     p    Post an article on a new topic.  _p_o_s_t_n_e_w_s(1) is  called
          to  post  the  new article, in the current newsgroup by
          default.  In order  to  permanently  resubscribe  to  a
          newsgroup  denied by `U', it is necessary to understand
          the format of the ._n_e_w_s_r_c file.  The ._n_e_w_s_r_c file  con-
          sists of two types of lines:

     option lines
          These start with the word `option' and contain the same
          arguments as the _r_e_a_d_n_e_w_s command on the command line.




Sun Release 4.1     Last change: 21 Nov 1990                    3






READNEWS(1)              USER COMMANDS                READNEWS(1)



     read newsgroup lines
          These have the format  <newsgroup>`:'  <number>,  where
          <number>  represents  the last item number seen in that
          particular newsgroup.  If the newsgroup has been unsub-
          scribed,  the `:' is replaced by a `!'.  To resubscribe
          the `!' must be changed back to a `:'.

FILES
     $HOME/.newsrc            options and list of previously read articles
     NEWSCTL/active           current newsgroups
     NEWSCTL/readnews.ctl     control file
     NEWSCTL/readnews.help    help file
     NEWSBIN/inject/postnews  for postings

SEE ALSO
     postnews(1), mail(1), ed(1)

HISTORY
     Originally written by Michael Rourke,  University  of  N.S.W
     (decvax!mulga!michaelr:elecvax).   Modified  and  simplified
     for the C News project.

BUGS
     The mustsub control line really ought to be able to  specify
     a subscription, i.e. multiple groups.

     This program is about as simple as they  come.   Almost  any
     seasoned news user will want something more complex.



























Sun Release 4.1     Last change: 21 Nov 1990                    4



