Article View: news.software.readers
Article #62856Re: slrn and marking articles
From: J.B. Nicholson-Owens
Date: Fri, 30 Jun 2000 00:00
Date: Fri, 30 Jun 2000 00:00
50 lines
2367 bytes
2367 bytes
Christiaan Keet wrote:
> Is there a way to easily mark a range of articles for download with
> slrn other than sitting there for long minutes keeping '#' depressed?
I've got a macro that will let you put down one (or more) numeric tags and
do whatever you want to the articles between them (including the tagged
articles). You could do something like this:
% Load the macro into slrn with your slrnrc.
interpret "by_the_numbers.sl"
Apply some numbers to the articles (or article range) you wish to save then
run some macro that might look like the following:
% Use the macro in slrn with some S-Lang code.
variable my_fp = fopen ("some_file", "a+");
if (my_fp == NULL)
verror ("Couldn\'t open file: %s", errno_string (errno));
define my_save_function ()
{
if (fputs (article_as_string (), my_fp) == -1)
verror ("Couldn\'t write to file: %s", errno_string (errno));
}
% Typically you'll use ONE of the following functions. Execute the
% function:
% on each tagged article.
By_The_Numbers->on_tags_do (&my_save_function);
% between each pair of tagged articles.
By_The_Numbers->between_tags_do (&my_save_function);
% on each tagged article for articles tagged 5 to 9.
() = By_The_Numbers->eval_between (5, 9, &my_save_function);
% from tag 5 to the highest tagged article.
() = By_The_Numbers->eval_between (5, &my_save_function);
if (fclose (my_fp) == -1)
verror ("Couldn\'t close file: %s", errno_string (errno));
Until I get a webpage with my macros on it I'll e-mail you a copy of
by_the_numbers.sl if you're interested. Documentation for the macro is in
the macro file.
Technical Details
Message-ID:
<slrn8lqcnj.7i.jbn@forestfield.org>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!not-for-mailReferences:
<slrn8lk7li.1ptt.keet@lorien.noc.uk.easynet.net>Show Full Headers
Complete Article Headers
Message-ID: <slrn8lqcnj.7i.jbn@forestfield.org> Subject: Re: slrn and marking articles Date: Fri, 30 Jun 2000 00:00:00 +0000 From: jbn@forestfield.org (J.B. Nicholson-Owens) References: <slrn8lk7li.1ptt.keet@lorien.noc.uk.easynet.net> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.mbox.zip!not-for-mail X-Deja-AN: 641037042 X-Trace: fu-berlin.de 962409214 782110 208.216.67.173 (16 [35848]) Organization: Forest Field User-Agent: slrn/0.9.6.2 (Unix) Newsgroups: news.software.readers