🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #10520

Re: How do you sort the .newsrc file

#10520
From: Russ Allbery
Date: Mon, 01 Aug 1994 20:48
28 lines
1632 bytes
bubai@ssc.sas.upenn.edu (Priyabroto Chatterjee) writes:
>What's the command for sorting the .newsrc file?

Assuming you are using a newsreader that doesn't do that for you, and
assuming you are on a Unix system and not some other platform that
also uses the name .newsrc, you'll probably want a shell script to do
that.

I use the following; no guarantees, but it seems to work well for me.
Save everything between the __ lines and make the script executable.
_____________________________________________________________________________

#!/bin/sh

# Written by Russ Allbery (rra@cs.stanford.edu)
# Updated February 17, 1994

cd ${DOTDIR-${HOME}}
mv -f .newsrc .oldnewsrc
sed 's/!.*/!/' < .oldnewsrc > .cn.temp
grep : .cn.temp > .newsrc
grep ! .cn.temp | sort >> .newsrc
rm -f .cn.temp
_____________________________________________________________________________

-- 
Russ Allbery
rra@genesis.gvg.tek.com
Technical Details
Message-ID: <31jn2l$3uk@gv-gate.gvg.tek.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!archive!mbox2nntp-news.software.readers.mbox.zip!bga.com!news.sprintlink.net!hookup!nntp.cs.ubc.ca!psgrain!news.tek.com!gv-gate.gvg.tek.com!genesis!rra
References: <31jiej$j6h@netnews.upenn.edu>

Show Full Headers
Complete Article Headers
Message-ID: <31jn2l$3uk@gv-gate.gvg.tek.com>
Subject: Re: How do you sort the .newsrc file
Date: Mon, 01 Aug 1994 20:48:21 +0000
From: rra@genesis.gvg.tek.com (Russ Allbery)
References: <31jiej$j6h@netnews.upenn.edu>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!archive!mbox2nntp-news.software.readers.mbox.zip!bga.com!news.sprintlink.net!hookup!nntp.cs.ubc.ca!psgrain!news.tek.com!gv-gate.gvg.tek.com!genesis!rra
Newsgroups: news.software.readers
Organization: Grass Valley Group, Grass Valley, CA
Lines: 28
NNTP-Posting-Host: genesis.gvg.tek.com