[Prev: SUBJECTREPLYRXP][Resources][TOC][Next: SUBJECTTHREADS]

SUBJECTSTRIPCODE


Syntax

Envariable

M2H_SUBJECTSTRIPCODE=Perl_expressions

Element

<SUBJECTSTRIPCODE>
Perl expressions...
</SUBJECTSTRIPCODE>

Command-line Option

-subjectstripcode Perl_expressions


Description

SUBJECTSTRIPCODE may be used to define Perl expressions to apply to message subjects when parsed by MHonArc. The main use of the resource is to edit message subjects before stored in the archive.

When defining the expressions, the subject text will be in the $_ variable. The value of $_ after all expressions are evaluated is the subject MHonArc will use for the message.


Default Setting

Nil


Resource Variables

N/A


Examples

Some mailing lists prefix all message subjects with a list identifier so subscribers can easily denote message from the list when received. However, the prefix can clutter MHonArc indexes. The SUBJECTSTRIPCODE can be used to strip the prefixes before messages are stored in the archive.

If the prefix is something like the following,

[LIST-NAME]:

the following SUBJECTSTRIPCODE setting can be used:

s/^\[LIST-NAME\]://;

Version

2.3.0


See Also


[Prev: SUBJECTREPLYRXP][Resources][TOC][Next: SUBJECTTHREADS]

$Date: 2002/12/10 04:08:04 $
MHonArc
Copyright © 1998, Earl Hood, mhonarc@mhonarc.org