[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Threading problem



Hello Giz,

thanks for your reply.

At 14:21 13.02.01 -0800, Giz wrote:
-------------------------
>The regex s/// is doing the substitution one time.  Add a /g at the end
>should make the substition global.  So:
>
>s/^\[List-Name\]\s*//g;
>
>I hope this works for you :)

Sorry, it didn't. No change.
You may have a look at
http://www.isoc-vn.org/mailarch/members/threads.html
which shows the current fragments of the future site.
Maybe I should mention, that I pipe the mails directly in sendmail's 
aliases file into MHonArc.

>Keep in mind, that it will also replace any other instances of the 
>listname
>in the subject, so if someone's message was
>"I'm having problems with THELIST", then that will be changed to "I'm 
>having
>problems with.".

No problems with that. Who would use the brackets [xx] in the subject?

>   I suppose a more sophisticated regex might be able to look
>for the re: first, and only replace in those instances, but I'll leave 
>that
>for someone better at regex than myself.

Hoping to find that "someone". ;)
This should be possible. I don't think, that my setup is so special. I 
would wonder, if not somebody had had the same problem already.

Cheers,
Stefan


>-----Original Message-----
>From: owner-mhonarc@ncsa.uiuc.edu [mailto:owner-mhonarc@ncsa.uiuc.edu]On
>Behalf Of Stefan Probst
>Sent: Tuesday, February 13, 2001 5:53 AM
>To: Earl Hood
>Cc: mhonarc@ncsa.uiuc.edu
>Subject: Re: Threading problem
>
>
>Hello Earl,
>
>first thanks for MHonArc. Even me lefthander, on a remote virtual server,
>got it running... :)
>
>I found your post in the archives.
>I tried:
><SUBJECTSTRIPCODE>
>s/^\[List-Name\]\s*//;
></SUBJECTSTRIPCODE>
>works fine for the first message in a thread.
>The second message gets treated as a thread (i.e. the "Re:" is
>recognized), but the [List-Name] is there again:
>
>* the subject
>*    Re: [List-Name] the subject
>                     ^---- there is a space
>
>Both in the main index and also in the thread index.
>How can do?
>
>Thanks!
>Stefan in Hanoi
>
>PS: Pls. cc to me, since I am not in the list.
>
>
>On Sat, 25 Sep 1999, Earl Hood wrote:
>
>  > On September 22, 1999 at 19:00, Serge Patrick KAPTO wrote:
>  >
>  > > [List-Name] Subject
>  > > [List-Name] Re: Subject
>  > >
>  > > I've used SUBJECTSTRIPCODE as follows.
>  > > <SUBJECTSTRIPCODE>
>  > > s/^\[List-Name\]//;
>  > ------------------^ Need a \s*
>  > > </SUBJECTSTRIPCODE>
>  > > It removes the list name from the subject lines, but fails to
>resolves the
>  > > thread problems. The explanation may be that the messages are
>threaded
>  > > before the regexp is applied.
>  >
>  > Try:
>  >
>  > <SUBJECTSTRIPCODE>
>  > s/^\[List-Name\]\s*//;
>  > </SUBJECTSTRIPCODE>
>  >
>  > The default SUBJECTREPLYRXP does not handle leading 
> whitespace.  Since
>  > your SUBJECTSTRIPCODE did not strip out the space after the
>  > list-name, SUBJECTREPLYRXP has no affect.
>  >
>  >
>  > > I've also tried SUBJECTREPLYRXP as follows
>  > > <SUBJECTREPLYRXP>
>  > > ^\s*\[List-Name\]\s*(sv|fwd|fw)[\[\]\d]*[:>-]+\s*
>  > > </SUBJECTREPLYRXP>
>  >
>  > This one is a little harder to get the desired effect.  For one,
>  > you leave out the ability to match "re", and it will not match
>  > against non-replies.  This should work:
>  >
>  > <SUBJECTREPLYRXP>
>  > ^\[List-Name\]\s*(?:(re|sv|fwd|fw)[\[\]\d]*[:>-]+\s*)?
>  > </SUBJECTREPLYRXP>
>  >
>  > The fixed SUBJECTSTRIPCODE is much cleaner.
>  >
>  >      --ewh
>  >


[Index of Archives]     [Bugtraq]     [Yosemite News]     [Mhonarc Home]