setting up a netnews interface

Brian Smithson (brian)
Fri, 26 Jun 92 12:21:35 PDT

I was asked, about setting up a netnews interface:

> Sounds very interesting - can you explain it to me in a
> little more specific detail - but still general.

Well, here's what I did:

The C code which is available via the archive server can be compiled
and put wherever. I modified news.c and x.c so that the temporary
file "news" was instead called ".xnews". More about the reasoning for
that later.

I added "xpress" to the ME entry in my netnews sys file so that xpress
articles wouldn't be rejected. I also put !xpress in all of the other
sys file entries just to make sure that the articles didn't get
redistributed outside of my system. They shouldn't, but I'm a little
paranoid about that.

I created a bunch of newsgroups. The ones which the current code uses
are listed below. I plan to deepen the categorization later, but the
original code seems to use these:

xpress.entertainment
xpress.finance
xpress.lifestyles
xpress.news
xpress.news.business
xpress.news.editorial
xpress.news.usa
xpress.news.world
xpress.shopping
xpress.tech
xpress.unknown
xpress.weather
xpress.xchange
xpress.xpress

To run the program, I cd to the incoming news spool directory (which is
something like /usr/spool/news/.rnews in Bnews, or something like
/usr/spool/news/in.coming in Cnews), su to the netnews UID, and execute
the following:

cat < $DEVICE | x -n 15 >> $XLOG 2>> $XERRLOG

where $DEVICE is the tty device to which your X*Press modem is connected,
$XLOG is where you want the X*Press new log info to go, and $XERRLOG
is where you want error messages to go.

What happens after that is that news articles accumulate in the file .xnews
and every 15 minutes ( -n 15 ) that file is renamed "news.N" where N
increments each time. My netnews system checks its incoming spool area
every 30 minutes for new batches and processes whatever it can see.
It can't see .xnews, hence the modification I mentioned earlier, but
it will see the news.N files and will process them as though they came
from a regular newsfeed.

It's all a little klugey, but it works OK. As I mentioned when I first
made the code available, there are a few problems with it. Nonetheless,
it's certainly a starting place.

I received some other code that I'll make available soon which probably does
a better job of interfacing to the netnews system, has a more complete
newsgroup categorization, and has the proper copyright attribution stuff.
It's not integrated into the first batch of code.

I'm still hoping that someone will volunteer to take all of this stuff
and create a really nice package. I'm simply not going to be able to put
the time into it, but I will coordinate making it available. If someone
out there is interested in talking about that, please let me know.

-- 
-Brian Smithson
 Motorola Inc., Computer Group, Commercial Systems Division
 10700 N. De Anza Boulevard, Cupertino, CA 95014 USA, (408)366-4104
 brian@csd.mot.com, {apple | pyramid}!motcsd!brian