🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
16 messages
16 total messages Started by Yasir Hassan Sat, 14 Apr 2001 00:08
Reading usenet archives
#51788
Author: Yasir Hassan
Date: Sat, 14 Apr 2001 00:08
149 lines
6875 bytes
Sorry if this is the wrong place to ask.

I've downloaded an archive of a particular usenet group. The archive is
simply a text file with all the postings and their headers.

Is there an app (on Windows, Mac or Linux, preferably windows) that can
import the archive and let me view it in a user-friendly way (e.g. with
messages threaded etc, as in something like Netscape of Outlook Express)?

Thanks,

Yasir

Here is a sample from the archive (with 2 postings) in case you don't know
what I mean

-------------------------------------------------------------------------
Path: not-for-mail
From: fjh@mundook.cs.mu.OZ.AU (Fergus Henderson)
Newsgroups: comp.lang.c++.moderated
Subject: Re: implicit_cast from Visual C++
Date: 2 Nov 1996 15:37:54 -0500
Organization: Comp Sci, University of Melbourne
Lines: 60
Sender: cppmods@netlab.cs.rpi.edu
Approved: harkness@airmail.net
Message-ID: <55gbf2$j75@netlab.cs.rpi.edu>
References: <55347v$bat@netlab.cs.rpi.edu> <55a8fb$mce@netlab.cs.rpi.edu>
<55cgsv$5bs@netlab.cs.rpi.edu>
X-Original-Date: 1 Nov 1996 17:09:57 GMT
X-Submission-Address: c++-submit@netlab.cs.rpi.edu

"Bradd W. Szonye" <bradds@concentric.net> writes:

>Fergus Henderson <fjh@murlibobo.cs.mu.OZ.AU> wrote in article
><55a8fb$mce@netlab.cs.rpi.edu>...
>> is there any good reason why isn't it part of the standard library?
>> If there is, I certainly haven't found it.
>
>The "best" name is difficult to decide on: should it be convert<>,
>implicit_cast<>, safe_cast<>, implicit_conversion<>, trivial_cast<>, or
>something else? The commitee has better things to do than argue over the
>name and editing of something that's trivial to implement.

The committee is a *standards* committee, it is *supposed* to standardize.
Having each programmer implement their own version of it with their own
name promotes needless diversity that makes code more difficult to
understand, not less.  Frankly, it wouldn't matter too much which name
the committee picks, there would be real benefits in choosing a single
standard name regardless of which name were chosen.

>There are not even any tricks to writing an implicit cast function; there's
>really only one way to do it, and it's a one-liner.

*Wrong*.  There are several ways to do it.  Both of the commonly seen
ones fail for certain cases.  It's very easy for experts to get it wrong
(in the sense of implementing convert<> in a way that fails for some cases).
I certainly have, and so has Bjarne Stroustrup, if the version that he
published in D&E is anything to go by.  It fails if the source type
doesn't have a copy constructor.  To do it properly, you need to pass
a reference, and to do that properly, you need to have four overloaded
versions.

    template <class T, U> inline T convert(U & u) { return u; }
    template <class T, U> inline T convert(const U & u) { return u; }
    template <class T, U> inline T convert(volatile U & u) { return u; }
    template <class T, U> inline T convert(const volatile U & u) { return
u; }

>Users can even rely on functional casts in this case; a good implementation
>should warn only about old-style casts that do non-implicit conversions.

I'm not convinced that a good C++ implementation will always warn
about using old-style casts, even for non-implicit conversions.
Remember, the C++ committee voted *not* to deprecate old-style casts.

What if I want to use macros from a header file written in C?
An implementation that warns about old-style casts would give
me irritating warnings if these macros contain casts.
I think we will still be using some header files written in C for
a very long time, perhaps for the forseeable future.

But the main problem is just that if a reader sees an old-style or
functional cast, they can't assume very much about the original
programmer's intention.

--
Fergus Henderson <fjh@cs.mu.oz.au>   |  "I have always known that the
pursuit
WWW: <http://www.cs.mu.oz.au/~fjh>   |  of excellence is a lethal habit"
PGP: finger fjh@128.250.37.3         |     -- the last words of T. S. Garp.

      [ Send an empty e-mail to c++-help@netlab.cs.rpi.edu for info ]
      [ about comp.lang.c++.moderated. First time posters: do this! ]


Path: not-for-mail
From: malak@access.digex.net (Michael Malak)
Newsgroups: comp.lang.c++.moderated
Subject: operator for char* based template
Date: 2 Nov 1996 16:24:28 -0500
Organization: Express Access Online Communications, Greenbelt, MD USA
Lines: 34
Sender: cppmods@netlab.cs.rpi.edu
Approved: harkness@airmail.net
Message-ID: <55ge6c$jjp@netlab.cs.rpi.edu>
X-Original-Date: 1 Nov 1996 13:07:23 -0500
X-Submission-Address: c++-submit@netlab.cs.rpi.edu

OK, why won't this compile?  (I'm using Microsoft Visual C++ 4.2):

-----------{ begin }---------------------------------------------
template< char* psz > class C {
 public:
    int i;
};

template< char* psz > inline int operator< (
    const C<psz>& lhs,  const C<psz>& rhs ) {      // first error
    return  lhs.i < rhs.i;
}                                                  // second error
----------{ end }-------------------------------------------------

I get two errors:

* error C2975: 'C' : invalid template argument '#1', constant
  expression expected

* error C2997: '<' : function parameter list must use template
  parameter 'psz'

Any other general information about using char* based templates
would be appreciated.  (I already know from researching DejaNews
that I must pass in a globally-defined char myArray[].  Any other
tips?)

--
Michael Malak         Home: malak@access.digex.net
Washington, DC        Work: malak@notes.sonix.com


      [ Send an empty e-mail to c++-help@netlab.cs.rpi.edu for info ]
      [ about comp.lang.c++.moderated. First time posters: do this! ]





Re: Reading usenet archives
#51798
Author: Player
Date: Sat, 14 Apr 2001 13:54
160 lines
7259 bytes
Where did you download those???


"Yasir Hassan" <no@spam.please> wrote in message
news:MhMB6.2427$482.12589@newsfeeds.bigpond.com...
> Sorry if this is the wrong place to ask.
>
> I've downloaded an archive of a particular usenet group. The archive is
> simply a text file with all the postings and their headers.
>
> Is there an app (on Windows, Mac or Linux, preferably windows) that can
> import the archive and let me view it in a user-friendly way (e.g. with
> messages threaded etc, as in something like Netscape of Outlook Express)?
>
> Thanks,
>
> Yasir
>
> Here is a sample from the archive (with 2 postings) in case you don't know
> what I mean
>
> -------------------------------------------------------------------------
> Path: not-for-mail
> From: fjh@mundook.cs.mu.OZ.AU (Fergus Henderson)
> Newsgroups: comp.lang.c++.moderated
> Subject: Re: implicit_cast from Visual C++
> Date: 2 Nov 1996 15:37:54 -0500
> Organization: Comp Sci, University of Melbourne
> Lines: 60
> Sender: cppmods@netlab.cs.rpi.edu
> Approved: harkness@airmail.net
> Message-ID: <55gbf2$j75@netlab.cs.rpi.edu>
> References: <55347v$bat@netlab.cs.rpi.edu> <55a8fb$mce@netlab.cs.rpi.edu>
> <55cgsv$5bs@netlab.cs.rpi.edu>
> X-Original-Date: 1 Nov 1996 17:09:57 GMT
> X-Submission-Address: c++-submit@netlab.cs.rpi.edu
>
> "Bradd W. Szonye" <bradds@concentric.net> writes:
>
> >Fergus Henderson <fjh@murlibobo.cs.mu.OZ.AU> wrote in article
> ><55a8fb$mce@netlab.cs.rpi.edu>...
> >> is there any good reason why isn't it part of the standard library?
> >> If there is, I certainly haven't found it.
> >
> >The "best" name is difficult to decide on: should it be convert<>,
> >implicit_cast<>, safe_cast<>, implicit_conversion<>, trivial_cast<>, or
> >something else? The commitee has better things to do than argue over the
> >name and editing of something that's trivial to implement.
>
> The committee is a *standards* committee, it is *supposed* to standardize.
> Having each programmer implement their own version of it with their own
> name promotes needless diversity that makes code more difficult to
> understand, not less.  Frankly, it wouldn't matter too much which name
> the committee picks, there would be real benefits in choosing a single
> standard name regardless of which name were chosen.
>
> >There are not even any tricks to writing an implicit cast function;
there's
> >really only one way to do it, and it's a one-liner.
>
> *Wrong*.  There are several ways to do it.  Both of the commonly seen
> ones fail for certain cases.  It's very easy for experts to get it wrong
> (in the sense of implementing convert<> in a way that fails for some
cases).
> I certainly have, and so has Bjarne Stroustrup, if the version that he
> published in D&E is anything to go by.  It fails if the source type
> doesn't have a copy constructor.  To do it properly, you need to pass
> a reference, and to do that properly, you need to have four overloaded
> versions.
>
>     template <class T, U> inline T convert(U & u) { return u; }
>     template <class T, U> inline T convert(const U & u) { return u; }
>     template <class T, U> inline T convert(volatile U & u) { return u; }
>     template <class T, U> inline T convert(const volatile U & u) { return
> u; }
>
> >Users can even rely on functional casts in this case; a good
implementation
> >should warn only about old-style casts that do non-implicit conversions.
>
> I'm not convinced that a good C++ implementation will always warn
> about using old-style casts, even for non-implicit conversions.
> Remember, the C++ committee voted *not* to deprecate old-style casts.
>
> What if I want to use macros from a header file written in C?
> An implementation that warns about old-style casts would give
> me irritating warnings if these macros contain casts.
> I think we will still be using some header files written in C for
> a very long time, perhaps for the forseeable future.
>
> But the main problem is just that if a reader sees an old-style or
> functional cast, they can't assume very much about the original
> programmer's intention.
>
> --
> Fergus Henderson <fjh@cs.mu.oz.au>   |  "I have always known that the
> pursuit
> WWW: <http://www.cs.mu.oz.au/~fjh>   |  of excellence is a lethal habit"
> PGP: finger fjh@128.250.37.3         |     -- the last words of T. S.
Garp.
>
>       [ Send an empty e-mail to c++-help@netlab.cs.rpi.edu for info ]
>       [ about comp.lang.c++.moderated. First time posters: do this! ]
>
>
> Path: not-for-mail
> From: malak@access.digex.net (Michael Malak)
> Newsgroups: comp.lang.c++.moderated
> Subject: operator for char* based template
> Date: 2 Nov 1996 16:24:28 -0500
> Organization: Express Access Online Communications, Greenbelt, MD USA
> Lines: 34
> Sender: cppmods@netlab.cs.rpi.edu
> Approved: harkness@airmail.net
> Message-ID: <55ge6c$jjp@netlab.cs.rpi.edu>
> X-Original-Date: 1 Nov 1996 13:07:23 -0500
> X-Submission-Address: c++-submit@netlab.cs.rpi.edu
>
> OK, why won't this compile?  (I'm using Microsoft Visual C++ 4.2):
>
> -----------{ begin }---------------------------------------------
> template< char* psz > class C {
>  public:
>     int i;
> };
>
> template< char* psz > inline int operator< (
>     const C<psz>& lhs,  const C<psz>& rhs ) {      // first error
>     return  lhs.i < rhs.i;
> }                                                  // second error
> ----------{ end }-------------------------------------------------
>
> I get two errors:
>
> * error C2975: 'C' : invalid template argument '#1', constant
>   expression expected
>
> * error C2997: '<' : function parameter list must use template
>   parameter 'psz'
>
> Any other general information about using char* based templates
> would be appreciated.  (I already know from researching DejaNews
> that I must pass in a globally-defined char myArray[].  Any other
> tips?)
>
> --
> Michael Malak         Home: malak@access.digex.net
> Washington, DC        Work: malak@notes.sonix.com
>
>
>       [ Send an empty e-mail to c++-help@netlab.cs.rpi.edu for info ]
>       [ about comp.lang.c++.moderated. First time posters: do this! ]
>
>
>
>
>


Re: Reading usenet archives
#51800
Author: Jeremy
Date: Sat, 14 Apr 2001 15:20
19 lines
1390 bytes
Yasir Hassan <no@spam.please> wrote:

> Sorry if this is the wrong place to ask.
> 
> I've downloaded an archive of a particular usenet group. The archive is
> simply a text file with all the postings and their headers.
> 
> Is there an app (on Windows, Mac or Linux, preferably windows) that can
> import the archive and let me view it in a user-friendly way (e.g. with
> messages threaded etc, as in something like Netscape of Outlook Express)?

It doesn't look like your archive has anything consistent (ie, machine
parsable) to tell where one message stops and another begins.  Not very
useful.  You'd probably have to throw something custom together and live
with it not being perfect.

-- 
Jeremy  |  jeremy@exit109.com
Re: Reading usenet archives
#51815
Author: those who know me have no need o...
Date: Sat, 14 Apr 2001 17:37
12 lines
1106 bytes
<987261616.891405@news.netscum.dk> divulged:
>Yasir Hassan <no@spam.please> wrote:

>It doesn't look like your archive has anything consistent (ie, machine
>parsable) to tell where one message stops and another begins.  

the two articles both had the path entry first.  i don't expect that 
to hold though.

-- 
okay, have a sig then
Re: Reading usenet archives
#51829
Author: Jeremy
Date: Sat, 14 Apr 2001 23:57
21 lines
1552 bytes
those who know me have no need of my name <not-a-real-address@usa.net> wrote:

>> It doesn't look like your archive has anything consistent (ie, machine
>> parsable) to tell where one message stops and another begins.
> 
> the two articles both had the path entry first.  i don't expect that 
> to hold though.

No, it won't; header order can vary, and Path is not always first.
Even if server-generated, DNEWS in particular does not put Path first;
and of course headers can also be client-generated, in which case they
can be in any order.

You'd basically have to write a script that looks for a blank line
followed by something that "looks like" news headers, and then take
that as the start of a new article.  And then go back and fix anything
that it fails to parse properly.

-- 
Jeremy  |  jeremy@exit109.com
Re: Reading usenet archives
#51842
Author: those who know me have no need o...
Date: Sun, 15 Apr 2001 10:33
18 lines
1505 bytes
<987292631.85806@news.netscum.dk> divulged:
>those who know me have no need of my name <not-a-real-address@usa.net> wrote:
>
>>> It doesn't look like your archive has anything consistent (ie, machine
>>> parsable) to tell where one message stops and another begins.
>> 
>> the two articles both had the path entry first.  i don't expect that 
>> to hold though.
>
>No, it won't; header order can vary, and Path is not always first.

exactly.  however i don't know what generated that file, so it is just
barely possible that it ensures that path is always first.  i find that 
unlikely, so i agree with you, in essence.

-- 
okay, have a sig then
Re: Reading usenet archives
#51852
Author: Rich Lafferty
Date: Mon, 16 Apr 2001 00:53
30 lines
2240 bytes
In news.software.nntp,
those who know me have no need of my name <not-a-real-address@usa.net> wrote:
> <987292631.85806@news.netscum.dk> divulged:
> >those who know me have no need of my name <not-a-real-address@usa.net> wrote:
> >
> >>> It doesn't look like your archive has anything consistent (ie, machine
> >>> parsable) to tell where one message stops and another begins.
> >> 
> >> the two articles both had the path entry first.  i don't expect that 
> >> to hold though.
> >
> >No, it won't; header order can vary, and Path is not always first.
> 
> exactly.  however i don't know what generated that file, so it is just
> barely possible that it ensures that path is always first.  i find that 
> unlikely, so i agree with you, in essence.

Sheesh, we've got computers, guys. We can find *out* if Path: is
always preceded by an empty line! :-)

(Can you make the file available on the Web or something?)

   -Rich

-- 
Rich Lafferty ----------------------------------------
 Nocturnal Aviation Division, IITS Computing Services
 Concordia University, Montreal, QC
rich@bofh.concordia.ca -------------------------------
Re: Reading usenet archives
#51853
Author: Yasir Hassan
Date: Mon, 16 Apr 2001 01:10
177 lines
7861 bytes
You can find the archive at

ftp://ftp.netlab.cs.rpi.edu/pub/comp.lang.c++.moderated


"Player" <tecaj@bonbon.net> wrote in message
news:9b9l1k$bql6$1@as121.tel.hr...
> Where did you download those???
>
>
> "Yasir Hassan" <no@spam.please> wrote in message
> news:MhMB6.2427$482.12589@newsfeeds.bigpond.com...
> > Sorry if this is the wrong place to ask.
> >
> > I've downloaded an archive of a particular usenet group. The archive is
> > simply a text file with all the postings and their headers.
> >
> > Is there an app (on Windows, Mac or Linux, preferably windows) that can
> > import the archive and let me view it in a user-friendly way (e.g. with
> > messages threaded etc, as in something like Netscape of Outlook
Express)?
> >
> > Thanks,
> >
> > Yasir
> >
> > Here is a sample from the archive (with 2 postings) in case you don't
know
> > what I mean
> >
>
> -------------------------------------------------------------------------
> > Path: not-for-mail
> > From: fjh@mundook.cs.mu.OZ.AU (Fergus Henderson)
> > Newsgroups: comp.lang.c++.moderated
> > Subject: Re: implicit_cast from Visual C++
> > Date: 2 Nov 1996 15:37:54 -0500
> > Organization: Comp Sci, University of Melbourne
> > Lines: 60
> > Sender: cppmods@netlab.cs.rpi.edu
> > Approved: harkness@airmail.net
> > Message-ID: <55gbf2$j75@netlab.cs.rpi.edu>
> > References: <55347v$bat@netlab.cs.rpi.edu>
<55a8fb$mce@netlab.cs.rpi.edu>
> > <55cgsv$5bs@netlab.cs.rpi.edu>
> > X-Original-Date: 1 Nov 1996 17:09:57 GMT
> > X-Submission-Address: c++-submit@netlab.cs.rpi.edu
> >
> > "Bradd W. Szonye" <bradds@concentric.net> writes:
> >
> > >Fergus Henderson <fjh@murlibobo.cs.mu.OZ.AU> wrote in article
> > ><55a8fb$mce@netlab.cs.rpi.edu>...
> > >> is there any good reason why isn't it part of the standard library?
> > >> If there is, I certainly haven't found it.
> > >
> > >The "best" name is difficult to decide on: should it be convert<>,
> > >implicit_cast<>, safe_cast<>, implicit_conversion<>, trivial_cast<>, or
> > >something else? The commitee has better things to do than argue over
the
> > >name and editing of something that's trivial to implement.
> >
> > The committee is a *standards* committee, it is *supposed* to
standardize.
> > Having each programmer implement their own version of it with their own
> > name promotes needless diversity that makes code more difficult to
> > understand, not less.  Frankly, it wouldn't matter too much which name
> > the committee picks, there would be real benefits in choosing a single
> > standard name regardless of which name were chosen.
> >
> > >There are not even any tricks to writing an implicit cast function;
> there's
> > >really only one way to do it, and it's a one-liner.
> >
> > *Wrong*.  There are several ways to do it.  Both of the commonly seen
> > ones fail for certain cases.  It's very easy for experts to get it wrong
> > (in the sense of implementing convert<> in a way that fails for some
> cases).
> > I certainly have, and so has Bjarne Stroustrup, if the version that he
> > published in D&E is anything to go by.  It fails if the source type
> > doesn't have a copy constructor.  To do it properly, you need to pass
> > a reference, and to do that properly, you need to have four overloaded
> > versions.
> >
> >     template <class T, U> inline T convert(U & u) { return u; }
> >     template <class T, U> inline T convert(const U & u) { return u; }
> >     template <class T, U> inline T convert(volatile U & u) { return u; }
> >     template <class T, U> inline T convert(const volatile U & u) {
return
> > u; }
> >
> > >Users can even rely on functional casts in this case; a good
> implementation
> > >should warn only about old-style casts that do non-implicit
conversions.
> >
> > I'm not convinced that a good C++ implementation will always warn
> > about using old-style casts, even for non-implicit conversions.
> > Remember, the C++ committee voted *not* to deprecate old-style casts.
> >
> > What if I want to use macros from a header file written in C?
> > An implementation that warns about old-style casts would give
> > me irritating warnings if these macros contain casts.
> > I think we will still be using some header files written in C for
> > a very long time, perhaps for the forseeable future.
> >
> > But the main problem is just that if a reader sees an old-style or
> > functional cast, they can't assume very much about the original
> > programmer's intention.
> >
> > --
> > Fergus Henderson <fjh@cs.mu.oz.au>   |  "I have always known that the
> > pursuit
> > WWW: <http://www.cs.mu.oz.au/~fjh>   |  of excellence is a lethal habit"
> > PGP: finger fjh@128.250.37.3         |     -- the last words of T. S.
> Garp.
> >
> >       [ Send an empty e-mail to c++-help@netlab.cs.rpi.edu for info ]
> >       [ about comp.lang.c++.moderated. First time posters: do this! ]
> >
> >
> > Path: not-for-mail
> > From: malak@access.digex.net (Michael Malak)
> > Newsgroups: comp.lang.c++.moderated
> > Subject: operator for char* based template
> > Date: 2 Nov 1996 16:24:28 -0500
> > Organization: Express Access Online Communications, Greenbelt, MD USA
> > Lines: 34
> > Sender: cppmods@netlab.cs.rpi.edu
> > Approved: harkness@airmail.net
> > Message-ID: <55ge6c$jjp@netlab.cs.rpi.edu>
> > X-Original-Date: 1 Nov 1996 13:07:23 -0500
> > X-Submission-Address: c++-submit@netlab.cs.rpi.edu
> >
> > OK, why won't this compile?  (I'm using Microsoft Visual C++ 4.2):
> >
> > -----------{ begin }---------------------------------------------
> > template< char* psz > class C {
> >  public:
> >     int i;
> > };
> >
> > template< char* psz > inline int operator< (
> >     const C<psz>& lhs,  const C<psz>& rhs ) {      // first error
> >     return  lhs.i < rhs.i;
> > }                                                  // second error
> > ----------{ end }-------------------------------------------------
> >
> > I get two errors:
> >
> > * error C2975: 'C' : invalid template argument '#1', constant
> >   expression expected
> >
> > * error C2997: '<' : function parameter list must use template
> >   parameter 'psz'
> >
> > Any other general information about using char* based templates
> > would be appreciated.  (I already know from researching DejaNews
> > that I must pass in a globally-defined char myArray[].  Any other
> > tips?)
> >
> > --
> > Michael Malak         Home: malak@access.digex.net
> > Washington, DC        Work: malak@notes.sonix.com
> >
> >
> >       [ Send an empty e-mail to c++-help@netlab.cs.rpi.edu for info ]
> >       [ about comp.lang.c++.moderated. First time posters: do this! ]
> >
> >
> >
> >
> >
>
>


Re: Reading usenet archives
#51854
Author: Rich Lafferty
Date: Mon, 16 Apr 2001 02:03
32 lines
2112 bytes
In news.software.nntp,
Yasir Hassan <no@spam.please> wrote:
> You can find the archive at
> 
> ftp://ftp.netlab.cs.rpi.edu/pub/comp.lang.c++.moderated

Oo. Moderated group, and it's the moderator's archive. That makes
things *so* much easier!

> > > Path: not-for-mail

I should've clued in from that. The path *is* always the first line
(and identical to that), so it should be straightforward to convert
the archives to something readable by a normal mail program. (Although
at some point between 1996 and the present, the moderator switched to
a different newsreader, so there'll be a couple of things to look for.)

You wouldn't happen to know if Netscape on Windows uses mbox for its
mail folders, would you?

In any case, this should be easy; I'm half a chapter away from
finishing my thesis, though, so I'd be happy to look at it in about a
day or so. :-)

  -Rich

-- 
Rich Lafferty ----------------------------------------
 Nocturnal Aviation Division, IITS Computing Services
 Concordia University, Montreal, QC
rich@bofh.concordia.ca -------------------------------
Re: Reading usenet archives
#51855
Author: Meowbox
Date: Mon, 16 Apr 2001 03:08
10 lines
1732 bytes
rich@bofh.concordia.ca (Rich Lafferty) wrote:

> You wouldn't happen to know if Netscape on Windows uses mbox for its
> mail folders, would you?

Yeah, Eudora should work okay too.
-- 
"I don't like this word 'meowbot'.  It is not a meowbot.  It is a device
which is meowing."  -Jeffy
Re: Reading usenet archives
#51862
Author: Rich Lafferty
Date: Mon, 16 Apr 2001 21:48
69 lines
3429 bytes
In news.software.nntp,
Yasir Hassan <no@spam.please> wrote:
> Sorry if this is the wrong place to ask.
> 
> I've downloaded an archive of a particular usenet group. The archive is
> simply a text file with all the postings and their headers.
> 
> Is there an app (on Windows, Mac or Linux, preferably windows) that can
> import the archive and let me view it in a user-friendly way (e.g. with
> messages threaded etc, as in something like Netscape of Outlook
> Express)?

There is now! Here's a short Perl program that'll convert a single
comp.lang.c++.moderated archive into an mbox-format mailbox, which any
Unix mailer -- and Netscape and Eudora but probably not Outlook -- can
read and thread. Some of the archive files don't have threading
information in them, though, so those will end up unthreaded in your
mailer (unless it supports subject threading in which case it'll be
naively threaded on Subject: instead of References:.)

If you find it useful, feel free to make it available to the rest of
comp.lang.c++.moderated; I haven't crossposted there because I've no
idea if this'd be acceptable for the group and don't want to wait to
see what the moderator thinks. :-)

Note that this was tested by looking at the existing archives; if they
decide to use a format which *isn't* a case of always separating
articles with the same header, then this will break (as it will on
the odd article which used the separating-header text in the body,
which didn't happen in any of the archives).

------8<----- cut here -----8<------
#!/usr/bin/perl -w
#
#  clcm2mbox -- convert comp.lang.c++.moderated archive into mbox mailbox
#
#  2001/04/16 Rich Lafferty <rich@bofh.concordia.ca>
#
#  Syntax: perl clpc2mbox archivename > mailboxname
#
#  Released into the public domain. NO WARRANTY.

use strict;
use vars qw($firstheader);

while (<>) {
    unless ($firstheader) {
	next if /^\s*$/;
	die "Input file is already in mbox format; doing nothing.\n"
	    if /^From /;
	$firstheader = (split(/:/, $_))[0];
    }
    print "From clcm2mbox\@localhost " . scalar localtime() . "\n"
	if /^$firstheader: /;

    print;
}
------8<----- cut here -----8<------

Hope this helps,

  -Rich

-- 
Rich Lafferty ----------------------------------------
 Nocturnal Aviation Division, IITS Computing Services
 Concordia University, Montreal, QC
rich@bofh.concordia.ca -------------------------------
Re: Reading usenet archives
#51869
Author: Yasir Hassan
Date: Tue, 17 Apr 2001 08:38
84 lines
4060 bytes
This is great! Thank you!

I've converted the text with the tool you provided, but I don't know how I
can view the converted file with the Netscape mail reader. Could you tell me
what to do please?

Thanks again,
Yasir Hassan



"Rich Lafferty" <rich@bofh.concordia.ca> wrote in message
news:slrn9dmq64.48l.rich@bofh.concordia.ca...
> In news.software.nntp,
> Yasir Hassan <no@spam.please> wrote:
> > Sorry if this is the wrong place to ask.
> >
> > I've downloaded an archive of a particular usenet group. The archive is
> > simply a text file with all the postings and their headers.
> >
> > Is there an app (on Windows, Mac or Linux, preferably windows) that can
> > import the archive and let me view it in a user-friendly way (e.g. with
> > messages threaded etc, as in something like Netscape of Outlook
> > Express)?
>
> There is now! Here's a short Perl program that'll convert a single
> comp.lang.c++.moderated archive into an mbox-format mailbox, which any
> Unix mailer -- and Netscape and Eudora but probably not Outlook -- can
> read and thread. Some of the archive files don't have threading
> information in them, though, so those will end up unthreaded in your
> mailer (unless it supports subject threading in which case it'll be
> naively threaded on Subject: instead of References:.)
>
> If you find it useful, feel free to make it available to the rest of
> comp.lang.c++.moderated; I haven't crossposted there because I've no
> idea if this'd be acceptable for the group and don't want to wait to
> see what the moderator thinks. :-)
>
> Note that this was tested by looking at the existing archives; if they
> decide to use a format which *isn't* a case of always separating
> articles with the same header, then this will break (as it will on
> the odd article which used the separating-header text in the body,
> which didn't happen in any of the archives).
>
> ------8<----- cut here -----8<------
> #!/usr/bin/perl -w
> #
> #  clcm2mbox -- convert comp.lang.c++.moderated archive into mbox mailbox
> #
> #  2001/04/16 Rich Lafferty <rich@bofh.concordia.ca>
> #
> #  Syntax: perl clpc2mbox archivename > mailboxname
> #
> #  Released into the public domain. NO WARRANTY.
>
> use strict;
> use vars qw($firstheader);
>
> while (<>) {
>     unless ($firstheader) {
> next if /^\s*$/;
> die "Input file is already in mbox format; doing nothing.\n"
>     if /^From /;
> $firstheader = (split(/:/, $_))[0];
>     }
>     print "From clcm2mbox\@localhost " . scalar localtime() . "\n"
> if /^$firstheader: /;
>
>     print;
> }
> ------8<----- cut here -----8<------
>
> Hope this helps,
>
>   -Rich
>
> --
> Rich Lafferty ----------------------------------------
>  Nocturnal Aviation Division, IITS Computing Services
>  Concordia University, Montreal, QC
> rich@bofh.concordia.ca -------------------------------


Re: Reading usenet archives
#51878
Author: Rich Lafferty
Date: Tue, 17 Apr 2001 14:02
22 lines
1952 bytes
In news.software.nntp,
Yasir Hassan <no@spam.please> wrote:
> This is great! Thank you!
> 
> I've converted the text with the tool you provided, but I don't know how I
> can view the converted file with the Netscape mail reader. Could you tell me
> what to do please?

No idea -- I don't use Netscape for mail. You need to tell Netscape
that that file is a mailbox. Try putting it with the rest of your
mailboxes and see if it figures it out, or try creating a mailbox
with the same name and then copying the converted mailbox over the
newly-created empty mailbox file.

  -Rich

-- 
Rich Lafferty ----------------------------------------
 Nocturnal Aviation Division, IITS Computing Services
 Concordia University, Montreal, QC
rich@bofh.concordia.ca -------------------------------
Re: Reading usenet archives
#51881
Author: Yasir Hassan
Date: Tue, 17 Apr 2001 23:37
31 lines
2198 bytes
Thanks. It all works now.


"Rich Lafferty" <rich@bofh.concordia.ca> wrote in message
news:slrn9doj80.2b1.rich@bofh.concordia.ca...
> In news.software.nntp,
> Yasir Hassan <no@spam.please> wrote:
> > This is great! Thank you!
> >
> > I've converted the text with the tool you provided, but I don't know how
I
> > can view the converted file with the Netscape mail reader. Could you
tell me
> > what to do please?
>
> No idea -- I don't use Netscape for mail. You need to tell Netscape
> that that file is a mailbox. Try putting it with the rest of your
> mailboxes and see if it figures it out, or try creating a mailbox
> with the same name and then copying the converted mailbox over the
> newly-created empty mailbox file.
>
>   -Rich
>
> --
> Rich Lafferty ----------------------------------------
>  Nocturnal Aviation Division, IITS Computing Services
>  Concordia University, Montreal, QC
> rich@bofh.concordia.ca -------------------------------


Re: Reading usenet archives
#51880
Author: Rich Lafferty
Date: Tue, 17 Apr 2001 23:58
15 lines
1549 bytes
In news.software.nntp,
Yasir Hassan <no@spam.please> wrote:
> Thanks. It all works now.

For my own reference, what'd it take to get Netscape to recognize the
mbox-ized archive?

  -Rich

-- 
Rich Lafferty ----------------------------------------
 Nocturnal Aviation Division, IITS Computing Services
 Concordia University, Montreal, QC
rich@bofh.concordia.ca -------------------------------
Re: Reading usenet archives
#51885
Author: Yasir Hassan
Date: Wed, 18 Apr 2001 02:05
24 lines
2114 bytes
I did what you suggested. I created an empty folder within Netscape, then
outside Netscape I overwrote the Netscape folder (which is just a file) with
the output of the perl utility you wrote. This worked with Netscape on Linux
and Windows.

"Rich Lafferty" <rich@bofh.concordia.ca> wrote in message
news:slrn9dpm4p.oo1.rich@bofh.concordia.ca...
> In news.software.nntp,
> Yasir Hassan <no@spam.please> wrote:
> > Thanks. It all works now.
>
> For my own reference, what'd it take to get Netscape to recognize the
> mbox-ized archive?
>
>   -Rich
>
> --
> Rich Lafferty ----------------------------------------
>  Nocturnal Aviation Division, IITS Computing Services
>  Concordia University, Montreal, QC
> rich@bofh.concordia.ca -------------------------------


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