[Mailman-Developers] mm-handler redux
Ron Jarrell
jarrell@vt.edu
Fri, 29 Mar 2002 07:33:10 -0500 (EST)
Ok. Diff against cvs again. Handles the VERP tokens just fine.
If I wasn't *still* here fiddling at 7am it'd probably be a tad more
elegant, but it work.
Index: mm-handler
===================================================================
RCS file: /cvsroot/mailman/mailman/contrib/mm-handler,v
retrieving revision 1.1
diff -r1.1 mm-handler
1c1
< #!/opt/bin/perl
---
> #!/usr/local/bin/perl
5d4
<
7,11c6,17
< ## testlist: "|/opt/pkgs/mailman/mail/wrapper post testlist"
< ## testlist-admin: "|/opt/pkgs/mailman/mail/wrapper mailowner testlist"
< ## testlist-request: "|/opt/pkgs/mailman/mail/wrapper mailcmd testlist"
< ## owner-testlist: testlist-admin
< ## testlist-owner: testlist-admin
---
> ##
> ##testlist: "|/home/mailman/mail/mailman post testlist"
> ##testlist-admin: "|/home/mailman/mail/mailman admin testlist"
> ##testlist-bounces: "|/home/mailman/mail/mailman bounces testlist"
> ##testlist-confirm: "|/home/mailman/mail/mailman confirm testlist"
> ##testlist-join: "|/home/mailman/mail/mailman join testlist"
> ##testlist-leave: "|/home/mailman/mail/mailman leave testlist"
> ##testlist-owner: "|/home/mailman/mail/mailman owner testlist"
> ##testlist-request: "|/home/mailman/mail/mailman request testlist"
> ##testlist-subscribe: "|/home/mailman/mail/mailman subscribe testlist"
> ##testlist-unsubscribe: "|/home/mailman/mail/mailman unsubscribe testlist"
> ##owner-testlist: testlist-owner
14,15c20,21
< $MMWRAPPER = "/opt/pkgs/mailman/mail/wrapper";
< $MMLISTDIR = "/var/mailman/lists";
---
> $MMWRAPPER = "/home/mailman/mail/mailman";
> $MMLISTDIR = "/home/mailman/lists";
122a129,130
> my @validfields = qw(admin bounces confirm join leave owner request
> subscribe unsubscribe);
124,126c132
< if ($addr =~ /(.*)-admin$/
< || $addr =~ /(.*)-owner$/
< || $addr =~ /^owner-(.*)$/) {
---
> if ($addr =~ /(.*)-(.*)\+.*$/) {
128,129c134,136
< $cmd = "mailowner";
< } elsif ($addr =~ /(.*)-request$/) {
---
> $cmd = "$2";
> } else {
> $addr =~ /(.*)-(.*)$/;
131c138,144
< $cmd = "mailcmd";
---
> $cmd = $2;
> }
> if (grep /^$cmd$/, @validfields) {
> if ($list eq "owner") {
> $list = $cmd;
> $cmd = "owner";
> }
190c203
< if (! -f "$MMLISTDIR/$list/config.db") {
---
> if (! -f "$MMLISTDIR/$list/config.pck") {
192c205
< if (! -f "$MMLISTDIR/$list/config.db") {
---
> if (! -f "$MMLISTDIR/$list/config.pck") {