|  | 
   
 |   |  |   
  
    | NEWSFISH(1) | FreeBSD General Commands Manual | NEWSFISH(1) |  
newsfish— batch
    USENET news reader with filter capabilities
 
  
    | newsfish | [ -CFVhlv] [-fconfig] [-cgroup] [-mlimit] [-nmaxRequests] [NNTP
      server] |  newsfishreads all unread articles in one
    or more newsgroups. Articles are then subjected to a set of user-defined
    filters, and those that pass are saved to a file in mailbox format. For
    speed, only article
    
    are tested.
 The options are as follows: 
  -CMark all articles in all newsgroups as read.-FForce newsfishto connect, even if the precommand
      terminates abnormally.-VDisplay version information and quit.-hDisplay command line summary and quit.-vTurns on the verbose flag.-fconfigSpecify an alternate server configuration file. The default is
      $HOME/.newsfish-servers.-cgroupMark all articles in group as read. You may specify
      multiple -cgroup
    options.-mlimitLimits all output files to limit bytes each. If
      limit ends with a ``b'', ``k'' or ``m'', then the
      actual byte limitation is limit times 512, 1024, or
      1048576 respectively.-lDisplay all available newsgroups on the server and quit.-nmaxRequestsSet the maximum number of outstanding NNTP requests. For values greater
      than 1, newsfishwill pipeline requests, allowing
      fuller utilization of your link. The recommended value is 10, though you
      may want to tune it up or down depending on the speed of your link. The
      default value is 1, meaning no pipelining is performed.NNTP serverThe NNTP server to connect to. If this is specified, it will override the
      environment variable NNTPSERVERdescribed
    below. The file $HOME/.newsfishrc defines what
    newsgroups to read and what filters to apply to their articles. The format
    of this file is fairly simple. The file is divided into "blocks".
    Each "block" defines a set of filters for a particular newsgroup
    and what file to save matching articles to. Each "block" consists
    of: 
  The name of the newsgroup followed by a colon. (':') The newsgroup name
      may contain asterisks, in which case the conditions for the block are
      applied to all blocks that match the newsgroup pattern. The wildcard
      matcher is fairly simple. It only supports wildcard prefixes (comp.sys.*),
      suffixes (*.hardware.misc), or both (*.hardware.*). You may also define a
      global match pattern ('*'), which will apply the conditions of the block
      to each and every other block.Zero or more lines beginning with an asterisk ('*'), a space ('
      '), followed by an
      egrep(1)
      style regular expression. The regular expression is case-insensitive.
      Leading and trailing whitespace are ignored. If more than one of these
      lines are defined, then an article's header must match
      all regular expressions in order for the article to be
      saved. Having no regular expression lines matches
      each and every
      article in the newsgroup. The sense of a regular expression line can be
      inverted if it is prefixed with a '!'.A filename relative to the directory from which
      newsfishis run. Use of absolute filenames is OK
      and is encouraged to eliminate ambiguity. Alternatively, if the first
      non-blank character is a pipe ('|') then the rest of the line names a
      program (and its arguments) that will receive the article on its standard
      input. The program is executed by ``/bin/sh -c''. Blank lines and lines beginning with a pound-sign ('#') are
    ignored. All leading and trailing whitespace on any line are also
  ignored. Multiple blocks can be defined for the same newsgroup, each with a
    differing set of regular expression lines (the output files need not be
    different). In any case, newsfishis smart enough to
    only process newsgroups once. For example, to save all articles from a group called
    "foo.bar" on the subject of "garply", you would define
    the block: 
foo.bar:
* ^Subject:.*garply
some/file As a more complex example, to save all articles from a group
    called "foo.baz" on the subject of "stuff", ignoring
    posts from anyone with the e-mail address of
    ⟨someone@spam.net⟩, define the block: 
foo.baz:
* !^From:.*someone@spam\.net
* ^Subject:.*stuff
another/file If a server configuration file
    ($HOME/.newsfish-servers by default) exists,
    newsfishwill attempt to read it. This file
    specifies per-server configuration details, allowingnewsfishto easily switch between different servers.
    Like $HOME/.newsfishrc, this file is also divided
    into "blocks". Each "block" defines a set of entries for
    one particular server. Each consists of: 
  The name of the NNTP server enclosed in square brackets ('[', ']'). This
      does not necessarily have to be the DNS name of the NNTP server. If it
      isn't the DNS name of the server, you must specify a valid
      "host" attribute, as explained below. When
      newsfishis run, either the environment variableNNTPSERVERor the command-line argument
      NNTP server must match the name of an NNTP server
      block. If not, the server is assumed to have the default
    configuration.Zero or more "attributes". Each "attribute" consists
      of a keyword and an argument, separated by one or more whitespace. See
      below. As usual, all leading and trailing whitespace are ignored. Any
    line that begins with a pound-sign ('#') is also ignored. A simple example that defines a news server called
    "mynewsserver": 
[mynewsserver]
host news.mynewsserver.com
config .newsfishrc-mynewsserver
newsrc .newsfishrc-newsrc-mynewsserver A complex example that defines a news server called
    "myisp". The news server requires authentication. Rather than
    sending our password through the network in the clear, we set up an
    ssh(1)
    tunnel to a host local to the news server. 
[myisp]
host localhost
port 1234
config .newsfishrc-myisp
newsrc .newsfishrc-newsrc-myisp
user myusername
password mypassword
preconnect ssh -f -x -L 1234:news:119 shell1.myisp.com sleep 30 The following server attributes are currently understood by
    newsfish: 
  host NNTP-hostThe host to connect to. If unspecified, the default is the name of the
      NNTP server (the name within the square brackets).port NNTP-portThe port to connect to. If unspecified, the default is 119.config config-fileThe filter definitions file to use. If unspecified, the default is
      $HOME/.newsfishrc. See the special note below
      regarding where newsfishfinds its configuration
      files.newsrc newsrc-fileThe newsrc file to use. Defaults to
      $HOME/.newsfish-newsrc if left unspecified. Since
      article numbers typically differ by NNTP server, you
      must specify a unique newsrc file for each server.password passwdIf the server requires authentication, this specifies the password to use.
      If this is defined, newsfishwill attempt
      authentication with the server. Otherwise, no authentication will be
      performed. Currently,newsfishonly supports the
      "original AUTHINFO" authentication scheme.user usernameIf the server requires authentication, this specifies the username to use.
      Note that for some NNTP servers, the username is optional. In this case
      this should be left unspecified.preconnect commandBefore connecting to the server, newsfishwill
      attempt to execute command.
      command is passed verbatim to ``/bin/sh -c''.newsfishwill wait for the command to complete
      before continuing. If the command exits with a non-zero result code
      (usually indicating error),newsfishwill
      immediately exit. This behavior can be controlled with the-Foption described above. Finally note that
      althoughnewsfishstrips leading and trailing
      whitespace, whitespace within command are
    preserved.postconnect commandSimilar to "preconnect", but command is
      executed after newsfishdisconnects from the
      server. 
  Unless a configuration filename is absolute (i.e. it begins with
      "/" or is relative to the current directory (i.e. it begins with
      "./" or "../"), newsfishexpects its configuration files to be relative to your home directory. For
      example:
    
      FilenameExpected Location.newsfishrc$HOME/.newsfishrc./myconfig./myconfig (in the current directory)/tmp/someconfig/tmp/someconfigfoo/bar$HOME/foo/bar This mapping applies to the server configuration file, all
        filter definition files, and all newsrc files. Note that this mapping
        does not apply to files which
        newsfishsaves articles to. Finally note that
        this mapping applies to the-fconfig option!If the -Cor-cgroup options are specified,newsfishwill not scan
      newsgroups as usual. Instead, it will catch up all matching newsgroups and
      simply quit. 
  NNTPSERVERThe NNTP server to connect to. This must be defined if
      NNTP server is not given on the command line. 
  $HOME/.newsfish-serversContains per-server configuration details. For an example, see
      dot.newsfish-servers.sample.
    
  $HOME/.newsfishrcThe file containing the filter definitions. See the file
      dot.newsfishrc.sample for an example.
    
  $HOME/.newsfish-newsrcContains the highest article number for each newsgroup already scanned by
      newsfish. This manual page was written by Allan
    Saddi ⟨allan@saddi.com⟩. 
  Visit the GSP FreeBSD Man Page Interface. Output converted with ManDoc.
 |