🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nn
3 messages
3 total messages Started by Peter Andersen Mon, 19 Sep 1994 08:41
nn batch reading?
#6429
Author: Peter Andersen
Date: Mon, 19 Sep 1994 08:41
15 lines
1252 bytes
It appears to me that I once read, that nn could be used to read articles
for me in my preferred groups while I am on holiday.

The idea should be to make a kill-file for autoselecting the articles, 
and then have a cron job preiodically start nn and then read and store
the selected articles on files (probably involving some macros in the init 
file).

I may be confusing nn with another program here, as I have been unable to
find information on this subject in the man-page and the FAQ.

Does anyone know if this is possible?

Sincerely,
Peter Andersen
Re: nn batch reading?
#6442
Author: Gerald Oskoboiny
Date: Fri, 23 Sep 1994 19:46
58 lines
2563 bytes
datpete@daimi.aau.dk (Peter Andersen) writes:

:
>The idea should be to make a kill-file for autoselecting the articles, 
>and then have a cron job preiodically start nn and then read and store
>the selected articles on files (probably involving some macros in the init 
>file).
:
>Does anyone know if this is possible?

I've been doing this for a while, with pretty good results. (Except
for lately, because nn has been dumping core on me. But it happens
for interactive sessions as well...)

First, define an init file to select and save the articles.
Mine is like this:

   set flow-control false
   unset embedded-header-escape

   on entry talk.bizarre
   '=' "^" 'S' "~/collected/$N" '+'
   end

   sequence
   talk.bizarre

(I don't know if all that is necessary, but that works for me).

Next, I have a shell script called "collect_articles", which is here:

   #!/bin/sh

   /usr/local/bin/nnbatch -Iinit2 talk.bizarre 2>&1 > /dev/null
   /home/goskoboi/bin/sort_articles 2>&1 > /dev/null

This script is called from a cron job that looks like this:

   0 5 * * * /home/goskoboi/bin/collect_articles 2>/dev/null > /dev/null

This reads news for me at 5:00 a.m. daily.

You might not want to do the same thing: you could probably call nnbatch
directly from cron. I wanted to do some post-processing of the articles,
which is why I used the intermediate shell script.

My particular setup is configured to save the entire newsgroup, but you
could easily change it to use auto-selection with a killfile. Maybe:

   on entry comp.*
      'S' "+$G/$N" '+'
   end

The important part is using the `nnbatch' program instead of `nn' (it
took me while to figure that out), and the stuff in the init file.
Hope this helps,

Gerald
Re: nn batch reading?
#6470
Author: FraLo
Date: Thu, 29 Sep 1994 18:32
83 lines
3867 bytes
In article <35vbaf$ekk@scapa.cs.ualberta.ca>, gerald@amisk.cs.ualberta.ca (Gerald Oskoboiny) writes:
|> datpete@daimi.aau.dk (Peter Andersen) writes:
|> 
|> :
|> >The idea should be to make a kill-file for autoselecting the articles, 
|> >and then have a cron job preiodically start nn and then read and store
|> >the selected articles on files (probably involving some macros in the init 
|> >file).
|> :
|> >Does anyone know if this is possible?
|> 
|> I've been doing this for a while, with pretty good results. (Except
|> for lately, because nn has been dumping core on me. But it happens
|> for interactive sessions as well...)
|> 
|>[instructions to get groups via nnbatch deleted] 

We have installed nn Release 6.5.0 here.
When I tried to read news in batch-mode, the following problem occured
(<group> stands for the name of a news-group, <init-file> for the name of a init-file):

- the articles in the group <group> I wrote to ~/collected with the command 

       /usr/local/bin/nnbatch -I<init-file> <group> 2>&1 > /dev/null

  are *not* marked as read.

  The articles are saved in ~/collected, but nnbatch terminates with

  "Attempt to read keyboard input in batch mode" and that's it. Is it possible that
  nnbatch hasn't updated the .newsrc-file?

  The <init-file> looks like this: 

       set flow-control false
       unset embedded-header-escape

       on entry <group>
       '=' "^" 'S' "~/collected/$N" '+'
       end

       sequence
       <group>

The next time I'm starting nn with the above nnbatch-command, I receive a core-dump.
Nevertheless, when I have deleted/moved the files in ~/collected away before, 
nnbatch does the job fine again.

So, can somebody help me in answering the question why the saved articels are
not marked as read? I do not want to have all available articles saved each time
I'm starting nnbatch. In my opinion it should be possible to use "nncheck <group>"
to find out if new articles are available in <group>, and if that's the case, then
I would start nnbatch to get the new, unread articles of <group>.
I have tried to circumvent the problem in explicitly marking
all articles as read (by using 'J' 'Y' in select-mode) in <group>,
but it has not worked, either.

Other questions I have are: 
- what is the difference between using keys in single-quotes
  and double-quotes in the init-file? 
- is there a difference between writing

  'x' 'y'

  and

  'x'
  'y'

  in the init-file?

Any help would be greatly appreciated.

Frank    

--------------------------------+-------------------------------------------
Frank Lonczewski                | E-mail: lonczews@informatik.tu-muenchen.de
Institute of Computer Science   |
Munich University of Technology |
80290 Munich                    | phone: (+49 | 0) 89 2105 2035
Germany                         |   fax: (+49 | 0) 89 2105 8180
--------------------------------+-------------------------------------------
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads