Is there a way to change the moderation flag of a member of a list from the command line, with Mailman?
There is a python script at http://www.msapiro.net/scripts/set_mod.py that might do what you need. I'm not aware of anything that actually comes with mailman to do this.
Turn ON moderated bit:
/usr/lib/mailman/bin/withlist -r mod.set $currentlist $user 1
Turn OFF moderated bit:
/usr/lib/mailman/bin/withlist -r mod.set $currentlist $user 0
In the above 2 statements, replace
$currentlist with the list name and
$user with the member's subscribed address.
#! /usr/bin/python # mod.py from Mailman import mm_cfg import sys def mod(list): for member in list.getMembers(): if list.getMemberOption(member, mm_cfg.Moderate): print member, "is moderated" def set(list, member, value): value = not not (int(value)) if list.isMember(member): list.Lock() list.setMemberOption(member, mm_cfg.Moderate, value) print "%s's moderated flag set to %d" % (member, value) list.Save() list.Unlock() else: print member, "not a member"