🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.readers
25 messages
25 total messages Started by Mats Peterson Mon, 21 Apr 2008 05:29
PNNTP, a simple NNTP client for Windows in Perl
#219700
Author: Mats Peterson
Date: Mon, 21 Apr 2008 05:29
5 lines
1172 bytes
http://www.geocities.com/matsp888/

-- 
Mats Peterson
http://www.geocities.com/matsp888/
Re: PNNTP, a simple NNTP client for Windows in Perl
#219753
Author: Nemesis
Date: Mon, 21 Apr 2008 19:11
14 lines
1718 bytes
Mats Peterson wrote:

> http://www.geocities.com/matsp888/

1. Put some screenshots somewhere ;-)
2. If it is written in Perl why should it work only on windows?

-- 
You can only be young once. But you can always be immature.
 _  _                  _
| \| |___ _ __  ___ __(_)___
| .` / -_) '  \/ -_|_-< (_-<
|_|\_\___|_|_|_\___/__/_/__/ http://xpn.altervista.org
Re: PNNTP, a simple NNTP client for Windows in Perl
#219758
Author: Blinky the Shark
Date: Mon, 21 Apr 2008 19:42
19 lines
2026 bytes
Nemesis wrote:

> Mats Peterson wrote:
> 
>> http://www.geocities.com/matsp888/
> 
> 1. Put some screenshots somewhere ;-) 2. If it is written in Perl why
> should it work only on windows?

<guessing class="from_non_perl_programmer"> Hard-coded dependence on Win
perl modules and/or Win FS structures? </guessing>


-- 
Blinky
Killing all posts from Google Groups
The Usenet Improvement Project: http://improve-usenet.org
Blinky: http://blinkynet.net
Re: PNNTP, a simple NNTP client for Windows in Perl
#219759
Author: Nemesis
Date: Mon, 21 Apr 2008 19:51
21 lines
2148 bytes
Blinky the Shark wrote:


>>> http://www.geocities.com/matsp888/
>> 1. Put some screenshots somewhere ;-) 2. If it is written in Perl why
>> should it work only on windows?
> <guessing class="from_non_perl_programmer"> Hard-coded dependence on Win
> perl modules and/or Win FS structures? </guessing>

probably it will be something like that, but Perl is a multiplatform language,
the OP has the opportunity to make his software work everywhere, he should use
it ;-)

-- 
Age is not a particularly interesting subject. Anyone can get old. All
you have to do is live long enough.
 _  _                  _
| \| |___ _ __  ___ __(_)___
| .` / -_) '  \/ -_|_-< (_-<
|_|\_\___|_|_|_\___/__/_/__/ http://xpn.altervista.org
Re: PNNTP, a simple NNTP client for Windows in Perl
#219761
Author: Blinky the Shark
Date: Mon, 21 Apr 2008 20:37
23 lines
2129 bytes
Nemesis wrote:

> Blinky the Shark wrote:
> 
> 
>>>> http://www.geocities.com/matsp888/
>>> 1. Put some screenshots somewhere ;-) 2. If it is written in Perl why
>>> should it work only on windows?
>> <guessing class="from_non_perl_programmer"> Hard-coded dependence on Win
>> perl modules and/or Win FS structures? </guessing>
> 
> probably it will be something like that, but Perl is a multiplatform
> language, the OP has the opportunity to make his software work everywhere,
> he should use it ;-)

Of course.  :)

-- 
Blinky
Killing all posts from Google Groups
The Usenet Improvement Project: http://improve-usenet.org
Blinky: http://blinkynet.net
Re: PNNTP, a simple NNTP client for Windows in Perl
#219795
Author: Gerry Ford
Date: Tue, 22 Apr 2008 02:59
41 lines
3076 bytes
"Blinky the Shark" <no.spam@box.invalid> wrote in message 
news:pan.2008.04.21.20.37.18.542739@thurston.blinkynet.net...
> Nemesis wrote:
>
>> Blinky the Shark wrote:
>>
>>
>>>>> http://www.geocities.com/matsp888/
>>>> 1. Put some screenshots somewhere ;-) 2. If it is written in Perl why
>>>> should it work only on windows?
>>> <guessing class="from_non_perl_programmer"> Hard-coded dependence on Win
>>> perl modules and/or Win FS structures? </guessing>
>>
>> probably it will be something like that, but Perl is a multiplatform
>> language, the OP has the opportunity to make his software work 
>> everywhere,
>> he should use it ;-)
>
> Of course.  :)
Mats has put a lot of work into making it look right on windows. 
Unfortunately, I haven't been able to get to the display part of it yet.

This part of it doesn't work like you think it would on windows:
my $pnntprc = "$ENV{'USERPROFILE'}\\pnntp.rc";
my $newsrc = "$ENV{'USERPROFILE'}\\news.rc";
my $killrc = "$ENV{'USERPROFILE'}\\kill.rc";
my @filter = ();
my $sigfile = "$ENV{'USERPROFILE'}\\signature.txt";

These all end up in folders that are hard to find.  I'd change that to be in 
the same folder as the script itself.  I'm still going through the 
killfiltering.  I'm not the quickest of creatures in perl.
-- 
"Life in Lubbock, Texas, taught me two things: One is that God loves you
and you're going to burn in hell.  The other is that sex is the most
awful, filthy thing on earth and you should save it for someone you love."

~~  Butch Hancock 

Re: PNNTP, a simple NNTP client for Windows in Perl
#219803
Author: Mats Peterson
Date: Tue, 22 Apr 2008 04:31
19 lines
1855 bytes
Nemesis <nemesis@nowhere.invalid> wrote:
> Mats Peterson wrote:
>
>> http://www.geocities.com/matsp888/
>
> 1. Put some screenshots somewhere ;-)
> 2. If it is written in Perl why should it work only on windows?
>

It is easily portable to Unix, but it has some Windows specific
stuff to make it simpler for Windows users, like using the
%USERPROFILE% directory instead of some %HOME% stuff. Most Windows
users don't have %HOME% defined. And it uses an ANSI console module
to be able to send escape sequences to the console, since the
Windows command shell in Win32 doesn't understand ANSI by default.

-- 
Mats Peterson
http://www.geocities.com/matsp888/
Re: PNNTP, a simple NNTP client for Windows in Perl
#219806
Author: Mats Peterson
Date: Tue, 22 Apr 2008 04:34
42 lines
2965 bytes
"Gerry Ford" <gerry@nowhere.ford> wrote:
>
> "Blinky the Shark" <no.spam@box.invalid> wrote in message 
> news:pan.2008.04.21.20.37.18.542739@thurston.blinkynet.net...
>> Nemesis wrote:
>>
>>> Blinky the Shark wrote:
>>>
>>>
>>>>>> http://www.geocities.com/matsp888/
>>>>> 1. Put some screenshots somewhere ;-) 2. If it is written in Perl why
>>>>> should it work only on windows?
>>>> <guessing class="from_non_perl_programmer"> Hard-coded dependence on Win
>>>> perl modules and/or Win FS structures? </guessing>
>>>
>>> probably it will be something like that, but Perl is a multiplatform
>>> language, the OP has the opportunity to make his software work 
>>> everywhere,
>>> he should use it ;-)
>>
>> Of course.  :)
> Mats has put a lot of work into making it look right on windows. 
> Unfortunately, I haven't been able to get to the display part of it yet.
>
> This part of it doesn't work like you think it would on windows:
> my $pnntprc = "$ENV{'USERPROFILE'}\\pnntp.rc";
> my $newsrc = "$ENV{'USERPROFILE'}\\news.rc";
> my $killrc = "$ENV{'USERPROFILE'}\\kill.rc";
> my @filter = ();
> my $sigfile = "$ENV{'USERPROFILE'}\\signature.txt";
>
> These all end up in folders that are hard to find.  I'd change that to be in 
> the same folder as the script itself.  I'm still going through the 
> killfiltering.  I'm not the quickest of creatures in perl.

It works exactly the way i think it would. And it's hardly hard to find.
It's the most logical place for configuration files, instead of
cluttering up My Documents.

-- 
Mats Peterson
http://www.geocities.com/matsp888/
Re: PNNTP, a simple NNTP client for Windows in Perl
#219824
Author: Jernej Simončič
Date: Tue, 22 Apr 2008 09:05
15 lines
2119 bytes
on Tue, 22 Apr 2008 04:34:53 GMT, Mats Peterson wrote:

> It works exactly the way i think it would. And it's hardly hard to find.
> It's the most logical place for configuration files, instead of
> cluttering up My Documents.

If you're targeting Windows, the only logical place for configuration files
is in either %APPDATA%\YourProgram or Local Settings\Application
Data\YourProgram (depending on whether the config is machine-specific or
not). On *nix it's usually $HOME\.yourprogram.

-- 
begin  .sig
< Jernej Simončič ><>◊<>< jernej simoncic at isg si >
end
Re: PNNTP, a simple NNTP client for Windows in Perl
#219826
Author: Mats Peterson
Date: Tue, 22 Apr 2008 09:57
19 lines
2229 bytes
Jernej Simon?i? <jernej@deepthought.ena.invalid> wrote:
> on Tue, 22 Apr 2008 04:34:53 GMT, Mats Peterson wrote:
>
>> It works exactly the way i think it would. And it's hardly hard to find.
>> It's the most logical place for configuration files, instead of
>> cluttering up My Documents.
>
> If you're targeting Windows, the only logical place for configuration files
> is in either %APPDATA%\YourProgram or Local Settings\Application
> Data\YourProgram (depending on whether the config is machine-specific or
> not). On *nix it's usually $HOME\.yourprogram.
>

I am fully aware of %APPDATA%, but in my book it's not a place to hold
user-edited files.

-- 
Mats Peterson
http://www.geocities.com/matsp888/
Re: PNNTP, a simple NNTP client for Windows in Perl
#219905
Author: Jernej Simončič
Date: Wed, 23 Apr 2008 08:15
13 lines
2026 bytes
on Tue, 22 Apr 2008 09:57:37 GMT, Mats Peterson wrote:

> I am fully aware of %APPDATA%, but in my book it's not a place to hold
> user-edited files.

If you're only aiming at home users, this may be acceptable. It definitely
isn't if you aim to ever have your application used in any kind of
corporate environment.

-- 
begin  .sig
< Jernej Simončič ><>◊<>< jernej simoncic at isg si >
end
Re: PNNTP, a simple NNTP client for Windows in Perl
#219906
Author: Mats Peterson
Date: Wed, 23 Apr 2008 08:16
16 lines
1987 bytes
Jernej Simon?i? <jernej@deepthought.ena.invalid> wrote:
> on Tue, 22 Apr 2008 09:57:37 GMT, Mats Peterson wrote:
>
>> I am fully aware of %APPDATA%, but in my book it's not a place to hold
>> user-edited files.
>
> If you're only aiming at home users, this may be acceptable. It definitely
> isn't if you aim to ever have your application used in any kind of
> corporate environment.
>

I'm obviously not.

-- 
Mats Peterson
http://www.geocities.com/matsp888/
Re: PNNTP, a simple NNTP client for Windows in Perl
#219947
Author: Gerry Ford
Date: Wed, 23 Apr 2008 23:32
62 lines
3788 bytes
"Mats Peterson" <matsp555@yahoo.com> wrote in message 
news:9fCPj.6455$R_4.5181@newsb.telia.net...
> Jernej Simon?i? <jernej@deepthought.ena.invalid> wrote:
>> on Tue, 22 Apr 2008 09:57:37 GMT, Mats Peterson wrote:
>>
>>> I am fully aware of %APPDATA%, but in my book it's not a place to hold
>>> user-edited files.
>>
>> If you're only aiming at home users, this may be acceptable. It 
>> definitely
>> isn't if you aim to ever have your application used in any kind of
>> corporate environment.
>>
>
> I'm obviously not.
Since I'm going in and changing these files all the time, I want them all 
together.  I think if I had a version that I thought was ready for a 
non-perl windows user, I would place them all in a scripts folder that is on 
the same level with the binaries.  Right out of the box, I would include the 
ansi console stuff in appropriate folders as well.  Maybe I should try a 
version that doesn't use it at all ....

Mats, a change for you:

#!/usr/bin/perl

use strict;
use warnings;
use Data::Dumper qw( Dumper);

my $killrc = "sample.killrc";
my @filter;
my @list1 = qw( Mon Tu Wed);
    open(FILE, "<$killrc") and do {
        @filter = ();
        foreach (<FILE>) {
            chomp; length or next; /^#/o and next;
            my $pat; eval ('$pat = qr/$_/') or do {prompt $@; next};
            push @filter, $pat;
        };
        close(FILE);

};
print @filter;
print @list1;
#print STDOUT "The list is " . Dumper( @list ) . "\n";

#  perl mats5.pl 2>text50.txt >text51.txt
__END__

As you can see, I'm picking apart your script like a guy in a wheelchair 
running a race.  You want to have parens around what you want to eval.  As 
it is, you're evaluating the do as well.  I've got a stomach flu. :-(
-- 
"Life in Lubbock, Texas, taught me two things: One is that God loves you
and you're going to burn in hell.  The other is that sex is the most
awful, filthy thing on earth and you should save it for someone you love."

~~  Butch Hancock 

Re: PNNTP, a simple NNTP client for Windows in Perl
#219950
Author: Gerry Ford
Date: Wed, 23 Apr 2008 23:36
16 lines
2284 bytes
Another thing.  Where is the ?-xism coming from?
(?-xism:^From:.*<cbfalconer@yahoo.com>)
(?-xism:^Subject:.*memset)
(?-xism:^Message-ID:.*googlegroups)
MonTuWed

If I wanted to filter out shoes and watch on subject as well, how do I do 
it.  80 degrees and I'm shivering.  Cheers,
-- 
"Life in Lubbock, Texas, taught me two things: One is that God loves you
and you're going to burn in hell.  The other is that sex is the most
awful, filthy thing on earth and you should save it for someone you love."

~~  Butch Hancock 

Re: PNNTP, a simple NNTP client for Windows in Perl
#219959
Author: Mike Yetto
Date: Thu, 24 Apr 2008 01:00
15 lines
2592 bytes
Bada bing Gerry Ford <gerry@nowhere.ford> bada bang:
> As you can see, I'm picking apart your script like a guy in a wheelchair 
> running a race.  You want to have parens around what you want to eval.  As 
> it is, you're evaluating the do as well.  I've got a stomach flu. :-(

What I see is colaborative software development in an
inappropriate public forum.

My suggestion is to take this to e-mail, or at least a perl
group.

Mike "why not get a room" Yetto
-- 
Pluralitas non est ponenda sine necessitas.
 - William of Ockham
Re: PNNTP, a simple NNTP client for Windows in Perl
#219961
Author: Mats Peterson
Date: Thu, 24 Apr 2008 01:39
21 lines
2298 bytes
"Gerry Ford" <gerry@nowhere.ford> wrote:
> Another thing.  Where is the ?-xism coming from?
> (?-xism:^From:.*<cbfalconer@yahoo.com>)
> (?-xism:^Subject:.*memset)
> (?-xism:^Message-ID:.*googlegroups)
> MonTuWed

They are the flags that result from compiling the regular expressions
with qr// in `read_killrc' as they are read from the killrc file.  Since
there is a '-' in front, they are all disabled, so they do nothing
to the patterns itself.

>
> If I wanted to filter out shoes and watch on subject as well, how do I do 
> it.  80 degrees and I'm shivering.  Cheers,

You would have to scan the article body in every article, I'm afraid.

-- 
Mats Peterson
http://www.geocities.com/matsp888/
Re: PNNTP, a simple NNTP client for Windows in Perl
#219960
Author: Mats Peterson
Date: Thu, 24 Apr 2008 01:46
33 lines
2644 bytes
Mats Peterson <matsp555@yahoo.com> wrote:
> "Gerry Ford" <gerry@nowhere.ford> wrote:
>> Another thing.  Where is the ?-xism coming from?
>> (?-xism:^From:.*<cbfalconer@yahoo.com>)
>> (?-xism:^Subject:.*memset)
>> (?-xism:^Message-ID:.*googlegroups)
>> MonTuWed
>
> They are the flags that result from compiling the regular expressions
> with qr// in `read_killrc' as they are read from the killrc file.  Since
> there is a '-' in front, they are all disabled, so they do nothing
> to the patterns itself.
>
>>
>> If I wanted to filter out shoes and watch on subject as well, how do I do 
>> it.  80 degrees and I'm shivering.  Cheers,
>
> You would have to scan the article body in every article, I'm afraid.
>

Sorry, I guess I misunderstood you. If you were to filter out shoes
and watch in the SUBJECT, you could do it two ways:

^Subject:.*(?:memset|shoes|watch)       (most efficient)

     or add two extra lines:

^Subject:.*shoes
^Subject:.*watch

-- 
Mats Peterson
http://www.geocities.com/matsp888/
Re: PNNTP, a simple NNTP client for Windows in Perl
#219963
Author: Gerry Ford
Date: Thu, 24 Apr 2008 02:11
34 lines
3082 bytes
"Mike Yetto" <myetto1@nycap.invalid> wrote in message 
news:slrn20080423205139.-73.twooffive@may.motzarella.org...
> Bada bing Gerry Ford <gerry@nowhere.ford> bada bang:
>> As you can see, I'm picking apart your script like a guy in a wheelchair
>> running a race.  You want to have parens around what you want to eval. 
>> As
>> it is, you're evaluating the do as well.  I've got a stomach flu. :-(
>
> What I see is colaborative software development in an
> inappropriate public forum.
>
> My suggestion is to take this to e-mail, or at least a perl
> group.
>
> Mike "why not get a room" Yetto

Anybody who wants to take control of his newsreading situation needs to be 
aware of a lot of the nuts and bolts issues that Mats and I are discussing.

There's no language more native to newsreaders than Perl.  I *am* discussing 
this script at a much more technical level in my perl ng.

I would say "learn to use a killfile" but that's precisely what we're 
talking about.

-- 
"Life in Lubbock, Texas, taught me two things: One is that God loves you
and you're going to burn in hell.  The other is that sex is the most
awful, filthy thing on earth and you should save it for someone you love."

~~  Butch Hancock 

Re: PNNTP, a simple NNTP client for Windows in Perl
#219964
Author: Mats Peterson
Date: Thu, 24 Apr 2008 02:14
33 lines
2859 bytes
"Gerry Ford" <gerry@nowhere.ford> wrote:
>
> "Mike Yetto" <myetto1@nycap.invalid> wrote in message 
> news:slrn20080423205139.-73.twooffive@may.motzarella.org...
>> Bada bing Gerry Ford <gerry@nowhere.ford> bada bang:
>>> As you can see, I'm picking apart your script like a guy in a wheelchair
>>> running a race.  You want to have parens around what you want to eval. 
>>> As
>>> it is, you're evaluating the do as well.  I've got a stomach flu. :-(
>>
>> What I see is colaborative software development in an
>> inappropriate public forum.
>>
>> My suggestion is to take this to e-mail, or at least a perl
>> group.
>>
>> Mike "why not get a room" Yetto
>
> Anybody who wants to take control of his newsreading situation needs to be 
> aware of a lot of the nuts and bolts issues that Mats and I are discussing.
>
> There's no language more native to newsreaders than Perl.  I *am* discussing 
> this script at a much more technical level in my perl ng.
>
> I would say "learn to use a killfile" but that's precisely what we're 
> talking about.
>

Never mind the bollocks, here's the Sex Pistols!

-- 
Mats Peterson
http://www.geocities.com/matsp888/
Re: PNNTP, a simple NNTP client for Windows in Perl
#219965
Author: Mats Peterson
Date: Thu, 24 Apr 2008 02:17
10 lines
1930 bytes
"Gerry Ford" <gerry@nowhere.ford> wrote:
>
> There's no language more native to newsreaders than Perl.
>

It is very suited for stuff like this, agree.

-- 
Mats Peterson
http://www.geocities.com/matsp888/
Re: PNNTP, a simple NNTP client for Windows in Perl
#219994
Author: Mike Dee
Date: Thu, 24 Apr 2008 10:27
10 lines
2550 bytes
"Gerry Ford" <gerry@nowhere.ford> wrote:

> X-Newsreader: Microsoft Outlook Express 6.00.2900.2180

^^^^^^^^^^^^^^^^

= wanker

-- 
dee
Re: PNNTP, a simple NNTP client for Windows in Perl
#219996
Author: Sn!pe
Date: Thu, 24 Apr 2008 10:41
16 lines
2886 bytes
Mike Dee <emteedee@invalid.invalid> wrote:

> "Gerry Ford" <gerry@nowhere.ford> wrote:
> 
> > X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
> 
> ^^^^^^^^^^^^^^^^
> 
> = wanker

I presume that's [ahem] a technical term?

-- 
^Ï^                          Sn!pe  <snipe@notforspam.fsnet.co.uk>

         ---------[  Just hold this yellow parcel.  ]---------
Re: PNNTP, a simple NNTP client for Windows in Perl
#219998
Author: Mike Dee
Date: Thu, 24 Apr 2008 10:57
20 lines
3037 bytes
snipe@spambin.fsnet.co.uk (Sn!pe) wrote:

> Mike Dee <emteedee@invalid.invalid> wrote:
> 
>> "Gerry Ford" <gerry@nowhere.ford> wrote:
>> 
>> > X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
>> 
>> ^^^^^^^^^^^^^^^^
>> 
>> = wanker
> 
> I presume that's [ahem] a technical term?

Yes, it is. And I should elaborate: It's a technical term for the 
combination of Gerry Ford + Ms OE, not simply Ms OE users in general, 
per se.

-- 
dee
Re: PNNTP, a simple NNTP client for Windows in Perl
#220004
Author: Mike Yetto
Date: Thu, 24 Apr 2008 12:25
27 lines
3017 bytes
Bada bing Mike Dee <emteedee@invalid.invalid> bada bang:
> snipe@spambin.fsnet.co.uk (Sn!pe) wrote:
>
>> Mike Dee <emteedee@invalid.invalid> wrote:
>> 
>>> "Gerry Ford" <gerry@nowhere.ford> wrote:
>>> 
>>> > X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
>>> 
>>> ^^^^^^^^^^^^^^^^
>>> 
>>> = wanker
>> 
>> I presume that's [ahem] a technical term?
>
> Yes, it is. And I should elaborate: It's a technical term for the 
> combination of Gerry Ford + Ms OE, not simply Ms OE users in general, 
> per se.
>

Does it involve banging his head on a helicopter door once too
often?

Mike "or perhaps the rotor" Yetto
-- 
Pluralitas non est ponenda sine necessitas.
 - William of Ockham
Re: PNNTP, a simple NNTP client for Windows in Perl
#220046
Author: Gerry Ford
Date: Thu, 24 Apr 2008 23:13
45 lines
3601 bytes
"Mike Yetto" <myetto1@nycap.invalid> wrote in message 
news:slrn20080424082430.-289.twooffive@may.motzarella.org...
> Bada bing Mike Dee <emteedee@invalid.invalid> bada bang:
>> snipe@spambin.fsnet.co.uk (Sn!pe) wrote:
>>
>>> Mike Dee <emteedee@invalid.invalid> wrote:
>>>
>>>> "Gerry Ford" <gerry@nowhere.ford> wrote:
>>>>
>>>> > X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
>>>>
>>>> ^^^^^^^^^^^^^^^^
>>>>
>>>> = wanker
>>>
>>> I presume that's [ahem] a technical term?
>>
>> Yes, it is. And I should elaborate: It's a technical term for the
>> combination of Gerry Ford + Ms OE, not simply Ms OE users in general,
>> per se.
>>
>
> Does it involve banging his head on a helicopter door once too
> often?
>
> Mike "or perhaps the rotor" Yetto

Ford was the best damn athlete we've had in the oval maybe ever.  He could 
have kicked W's ass handily, and he was a repub before this neocon cabal.

As to the wanker charge, I'll repeat what I told the Mormon authorities when 
faced with the "worthiness interview" before leaving on a mission, twenty 
years ago:  "90 % of BYU's males masturbate, 10% lie; I'd rather be a 
masturbator than a liar."

I achieved local celebrity status for this moment of candor.
-- 
"Life in Lubbock, Texas, taught me two things: One is that God loves you
and you're going to burn in hell.  The other is that sex is the most
awful, filthy thing on earth and you should save it for someone you love."

~~  Butch Hancock 

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