31 Dec
2020
31 Dec
'20
10:52 a.m.
- Abhilash Raj (maxking@asynchronous.in) [201219 14:54]:
You can iterate over the Users and their addresses in
mailman shell
as well:>>> from mailman.interfaces.usermanager import IUserManager >>> from zope.component import getUtility >>> user_manager = getUtility(IUserManager) >>> for user in user_manager.users: ... for address in user.addresses: ... address.display_name = user.display_name ... >>> commit()
I think it would be useful (for others who try it) to have just these snippets somewhere (also as examples what could be achived by mailman shell). I'm happy to add them myself if possible, but the wiki seems to be mailman 2 centric?
What would be the appropriate place then?
Regards, Andi