🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nn
5 messages
5 total messages Started by Ritesh Patel Sat, 26 Jun 1993 03:32
finding "India" and not "Indiana"
#4355
Author: Ritesh Patel
Date: Sat, 26 Jun 1993 03:32
14 lines
1077 bytes
How do I find articles that have India in the subject without getting articles
that have Indiana in the subject. Right now I use the following:
	nn -Q -mxX -s/india clari
and I get all articles that have india and indiana in the subject from all
clari groups. I ject want india.

Thank you.


-- 
  Ritesh Patel
  clp@tiamat.umd.umich.edu
  71011.1736@compuserve.com
Re: finding "India" and not "Indiana"
#4352
Author: John Vanderpool
Date: Mon, 28 Jun 1993 04:57
30 lines
1880 bytes
clp@tiamat.umd.umich.edu (Ritesh Patel) writes:


>How do I find articles that have India in the subject without getting articles
>that have Indiana in the subject. Right now I use the following:
>	nn -Q -mxX -s/india clari
>and I get all articles that have india and indiana in the subject from all
>clari groups. I ject want india.

see any manpage (regexp(5) on some systems) or any book on regular expressions
i don't know much about them myself except for simple ones

maybe -s/"india " will work better but i'm sure there is a more bullet-proff
regexp than that since "india " wouldn't find "india<tab>" or "india<lf>" i
don't think

		fish

>Thank you.


>-- 
>  Ritesh Patel
>  clp@tiamat.umd.umich.edu
>  71011.1736@compuserve.com
--
John R. Vanderpool     INTERNET: fish@eosdata.gsfc.nasa.gov
NASA/GSFC/HSTX         VOX: 301-513-1683  FAX: 301-513-1608
"Don't put me in a frame upon the mantle, for memories grow dusty, old & gray;
 Don't send me no distant salutations, silly souveneirs from far away." -jrr
Re: finding "India" and not "Indiana"
#4358
Author: Soh Kam Hung
Date: Mon, 28 Jun 1993 23:46
19 lines
1498 bytes
fish@daacdev1.stx.com (John Vanderpool) writes:
>clp@tiamat.umd.umich.edu (Ritesh Patel) writes:
>>[ ... Finding the string ``India'' instead of ``Indiana''.
>[... Suggests regular expressions ... ]

Try the regular expression: \<india\>.  \< matches an empty string at
the start of a word, \> matches an empty string at the end of a word.
Tabs or spaces on either side of the word are effectively ignored.

In C shell, stop the shell from expanding < and > by putting them in
single quotes.  Eg:

$ nn -Q -mxX '-s/\<india\>' soc

Regards,

-- 
Soh Kam Hung, Network Management Research,     | h.soh@trl.oz.au  
TRL, POB 249 Clayton, Victoria 3168, Australia | +61 3 253 6638
Re: finding "India" and not "Indiana"
#4369
Author: Nancy McGough
Date: Wed, 30 Jun 1993 19:08
29 lines
1888 bytes
clp@tiamat.umd.umich.edu (Ritesh Patel) writes:
>How do I find articles that have India in the subject without getting articles
>that have Indiana in the subject. Right now I use the following:
>	nn -Q -mxX -s/india clari
>and I get all articles that have india and indiana in the subject from all
>clari groups. I ject want india.

I haven't yet played around with nn's command line arguments 
but I do a similar thing to what you want to do via my kill/select
file.  Here's the line I use to autoselect any articles that
contain nn in the subject:

:+s/:^nn | nn | nn$

This means select any article that starts with "nn ",
contains " nn ", or ends with " nn".

You could do a similar thing with India.  If you wanted
to restrict it to the clari.* newsgroups you could use:

/^clari:+s/:^India | India | India$

If you want to select articles that contain India and
kill all articles that don't contain India you could
do this:
/^clari:~+s/:^India | India | India$

Hope this is helpful
Nancy
Re: finding "India" and not "Indiana"
#4380
Author: Nancy McGough
Date: Thu, 01 Jul 1993 19:30
20 lines
1424 bytes
I wrote:
>Here's the line I use to autoselect any articles that
>contain nn in the subject:
>
>:+s/:^nn | nn | nn$
>
>This means select any article that starts with "nn ",
>contains " nn ", or ends with " nn".

If you want to include things like "nov+nn", "nn;"
etc., i.e., nn surrounded by any non-alpha character
then the following is better:

:+s/:^nn[^a-zA-Z]|[^a-zA-Z]nn[^a-zA-Z]|[^a-zA-Z]nn$


[^a-zA-Z] means anything other than an alphabetic
character.  

  -Nancy
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