Article View: news.software.readers
Article #9522Re: How do I select multiple topics with trn
From: Wayne Davison
Date: Mon, 13 Jun 1994 09:32
Date: Mon, 13 Jun 1994 09:32
52 lines
2848 bytes
2848 bytes
According to David Goldenberg <p23568@tcville.edsg.hac.com>:
> My question is, can I scan for topic a or topic b
> ... or topic n with one command? I tried /topica|topicb/a
> and other things I could think of but nothing worked.
You almost got it right, you just need to put a backslash in front of
the vertical bar:
/topica\|topicb\|topicc/a
> Is there a way to write a macro that scans unread articles for topic
> a and selects any that are found and then scans unread articles for
> topic b and selects any that are found ... and then scans unread
> articles for topic n and selects any that are found?
I'm not sure exactly what you mean here. Do you want it to loop,
prompting for topics? If so I don't see what that buys you over
doing selections in the selector: just type '/topica' <CR> '/topicb'
<CR> ... '/topicn' <CR> and then press return again to start reading
the selected topics.
If you want a hard-wired set of topics on a per-group basis, type
Ctrl-K while inside the group to edit your kill file and put the
select command in there. Maybe you were unaware how to write a
searching selection command. Use one of the following:
/topica\|topicb\|topicc/:+
or /topica\|topicb\|topicc/:++
The first one just selects the matched articles. The second one selects
the whole thread (including related subjects) and is the default command
in the thread selector. The difference is particularly important if you
are selecing via the From line:
/author/f:+ Selects just author's articles.
/author/f:++ Selects the thread author's articles are in.
Finally, if you want a hard-wired set of topics that you can start
anywhere via macro, put the select command in your .trnmac file:
*s /topica\|topicb\|topicc/:+
(I chose to use *s as a random macro sequence that doesn't get in the
way of any other commands.)
One more thing, if you're using an old version of trn (or rn for that
matter) I believe that using complex regular expressions can crash on
you. Modern trn versions (3.4.1 is the latest with 3.5 almost released)
have had some bug fixes in the regex area.
--
Wayne Davison
davison@borland.com
Technical Details
Message-ID:
<CrBx5K.ICx@borland.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!nntp.gmd.de!xlink.net!howland.reston.ans.net!usc!elroy.jpl.nasa.gov!decwrl!borland.com!davisonReferences:
<2t7qf8$arl@hacgate2.hac.com>Show Full Headers
Complete Article Headers
Message-ID: <CrBx5K.ICx@borland.com> Subject: Re: How do I select multiple topics with trn Date: Mon, 13 Jun 1994 09:32:08 GMT From: davison@borland.com (Wayne Davison) References: <2t7qf8$arl@hacgate2.hac.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!nntp.gmd.de!xlink.net!howland.reston.ans.net!usc!elroy.jpl.nasa.gov!decwrl!borland.com!davison Newsgroups: news.software.readers Organization: Borland International Lines: 52