Skip to Content.
Sympa Menu

en - Re: [sympa-users] Custom mhonarc script, trouble after upgrade...

Subject: The mailing list for listmasters using Sympa

List archive

Chronological Thread  
  • From: Marco Gaiarin <address@concealed>
  • To: Marco Gaiarin <address@concealed>
  • Cc: address@concealed
  • Subject: Re: [sympa-users] Custom mhonarc script, trouble after upgrade...
  • Date: Thu, 28 Feb 2019 22:15:45 +0100


Again, i reply to myself.

> Something like:
>
> https://sympa-community.github.io/manual/man/Sympa-Message-Plugin.3.html
> Seems well-suited, probably a hook in pre_distribute will suffice... right?

I've tried to read /usr/share/sympa/lib/Sympa/Message/Plugin/FixEncoding.pm,
the only example available, but seems rather obscure to me (but, clearly,
i don't know perl decently...).

Seems to me that:

a) i need a module called
/usr/share/sympa/lib/Sympa/Message/Plugin/Newsgate.pm

b) where exist a package called:
package Sympa::Message::Plugin::Newsgate;

c) where there's a function/sub that have to be called 'pre_distribute'

d) the third 'variable' passed to that function is the message, coded using
the internal format, depicted in 'man Sympa::Message'.


e) Ok, done that i need to translate listname into newsgroup name; i have a
file for that, i can do simple regexp in perl, but i've not clear how to
get the listname. Sympa::Message speaks about 'context' but really i've not
understood what mean...

f) eventually done that, i need to pipe message (raw message) to my gateway
script; seems i need to use $message->dump() but really i've not understood
how.


Someone can help me?! Thanks. ;-)

--
Dio del cielo se mi vorrai
in mezzo agli altri uomini mi cercherai (F. De Andre`)





Archive powered by MHonArc 2.6.19+.

Top of Page