🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nn
4 messages
4 total messages Started by William Devine II Tue, 26 Jan 1993 00:26
unsubscribe ALL groups?
#3665
Author: William Devine II
Date: Tue, 26 Jan 1993 00:26
13 lines
1222 bytes
Is there anyway to have a new .newsrc file put a new users directory that
has all of the groups unselected?  Also, if this is possible, how could
they edit the .newsrc file with vi to add whichever and only whichever groups
they desired.  This is the much preferred way than to have to go to 
all 2800 groups and Unsubscribe.  any takers?

william c devine, ii

--
                                  William C. Devine, II
------------------------------------------------------------------------
DECnet:     pvhep::devine       Internet:   wdevine@andrew.cea.pvamu.edu
            		                    devine@pvhep.pvamu.edu
Re: unsubscribe ALL groups?
#3668
Author: Michael Masterson
Date: Tue, 26 Jan 1993 19:04
21 lines
1681 bytes
wdevine@andrew.cea.pvamu.edu (William Devine II) writes:

>Is there anyway to have a new .newsrc file put a new users directory that
>has all of the groups unselected?  Also, if this is possible, how could
>they edit the .newsrc file with vi to add whichever and only whichever groups
>they desired.  This is the much preferred way than to have to go to 
>all 2800 groups and Unsubscribe.  any takers?

How 'bout, (in vi) :%s/:.*$/!/

that'll unsubscribe all groups (after a nn -a0) then the person can
just wander through the .newsrc file and do a $r: for those groups they
like... it's a lot quicker.

cheers.

-- 
Operated by professionals, do not try at home, see your dealer for details.
Your mileage may vary. Call before digging. Best if eaten by date on package.
Apply only to affected area. Batteries not included. Member FDIC.
Michael Masterson                                   mmaster@parnasus.dell.com
Re: unsubscribe ALL groups?
#3672
Author: Stefan Schwarz
Date: Wed, 27 Jan 1993 09:54
20 lines
1579 bytes
wdevine@andrew.cea.pvamu.edu (William Devine II) writes:

>Is there anyway to have a new .newsrc file put a new users directory that
>has all of the groups unselected?  Also, if this is possible, how could
>they edit the .newsrc file with vi to add whichever and only whichever groups
>they desired.  This is the much preferred way than to have to go to 
>all 2800 groups and Unsubscribe.  any takers?

How about:
mv .newsrc .newsrc.orig 
sed -e 's/:/!/' .newsrc.orig > .newsrc

This changes all groups to unsubscribed.
After then, you could change '!' to ':' for your favourite groups within an editor.

	Stefan
--
Stefan Schwarz                            University of the armed forces
Laboratory for graphical data processing  W-8014 Neubiberg, FRG
--
Re: unsubscribe ALL groups?
#3685
Author: Kristian Koehntopp
Date: Fri, 29 Jan 1993 13:42
104 lines
3739 bytes
In <1k20g1INN80@tamsun.tamu.edu> wdevine@andrew.cea.pvamu.edu (William Devine II) writes:
>Is there anyway to have a new .newsrc file put a new users directory that
>has all of the groups unselected?  Also, if this is possible, how could
>they edit the .newsrc file with vi to add whichever and only whichever groups
>they desired.  This is the much preferred way than to have to go to 
>all 2800 groups and Unsubscribe.  any takers?

At tpki.toppoint.de upon creation of a new user the following
script (and many more) is being run. The script unsubscribes to
all groups but tp.* and kiel.* (which are local). Thus, new
users are not being hit by 2800 groups with n thousand unread
articles.

Kristian

#
# @(#) newsrc - Creation/deletion of the users .newsrc
#
# (C) Copyright 1991 Kristian Koehntopp
#     All rights reserved.
#
# The script is being called from mkuser with a preinitialized
# environment. It will create a .newsrc in the users $HOME.	
#
# 15 Nov 1991  KK  file created.
#

# Create .newsrc from active file
ACTIVE=/usr/local/lib/news/active

##############################################################################
#
# Put a .newsrc to stdout.
#
newsrcfile()
{
  # All groups will be unsubscribed except for the local
  # groups tp.* and kiel.*
  cat $ACTIVE | sort | awk '
match($1, /^tp\./) || match($1, /^kiel\./) {
  printf "%s:\n", $1
}

! (match($1, /^tp\./) || match($1, /^kiel\./)) {
  printf "%s!\n", $1
}
' 
}

##############################################################################
#
# create .newsrc (MK_ variables preinitialized from mkuser)
#
cr_newsrc()
{
  if [ ! -d "$MK_HOME" ]
  then
    echo "$MK_HOME ist kein Directory?"
    return 1
  fi

  newsrcfile > $MK_HOME/.newsrc
  sleep 2
  chmod 700 $MK_HOME/.newsrc
  chgrp $MK_GID $MK_HOME/.newsrc
  chown $MK_UID $MK_HOME/.newsrc
  echo "$MK_HOME/.newsrc angelegt."
  return 0
}

##############################################################################
#
# delete .newsrc
#
rm_newsrc()
{
  if [ -f "$MK_HOME/.newsrc" ]
  then
    cd $MK_HOME
    rm -f .newsrc
    echo "$MK_HOME/.newsrc geloescht."
    return 0
  else
    echo "$MK_HOME/.newsrc konnte nicht geloescht werden."
    return 1
  fi
}

########## main

mode=$1

case "$mode" in
  create) cr_newsrc ; rc=$? ;;
  remove) rm_newsrc ; rc=$? ;;
esac

exit $rc

-- 
[ (Kristian Koehntopp) (Harmsstrasse 98) (2300 Kiel) (+49 431 676689) ]
/a{def}def /e{exch}a /p{currentpoint e pop}a /m{moveto}a /s{sub}a
/Times-BoldItalic findfont setfont 36 36 scale 0 4 m{p 12 2 index stringwidth
pop s 2 div e m show p 0 e 1 s dup 4 e s 4 div setgray m}forall showpage
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