[Mailman-Developers] Multiple admins in 'newlist?'

Christopher Lindsey lindsey@ncsa.uiuc.edu
Sat, 13 Mar 1999 16:14:04 -0600 (CST)


I was having a bear of a time figuring out how to get multiple admins
specified when creating a new list.  I may be missing something obvious
here, but I ended up patching newlist to allow multiple addresses
delimited by spaces (I know, it's not the right thing to do in case
of quoted-string addresses, but until that's fixed throughout all of
Mailman this will do).

Undoubtedly the notification could be lumped together into the same
SMTP transaction, but I don't see it being a problem given how often
this will be run (and one could argue that admin notification for
a new list should be sent individually to track failures in cases
where the admin forwards without rewriting the envelope, since their
mail is much more important to be able to debug than users (but
I'm just saying that to cover my butt)).

(NOTE:  I'm not a Mailman developer, and this is not an official patch.
Harald et al, should I be sending these to the list, or just to you folks?)

Chris

P.P.S.  This is against the current CVS tree as of the timestamp
        on the diff.

----------------------------------------------------------------------
*** /home/staff/lindsey/cvs/mailman/bin/newlist	Tue Mar  9 21:26:12 1999
--- bin/newlist	Sat Mar 13 15:53:49 1999
***************
*** 29,34 ****
--- 29,35 ----
  Note that list-names are forced to lowercase.
  """
  
+ from string import *
  import sys, os, string
  import time
  import paths                                      # path hacking
***************
*** 74,81 ****
      if len(argv) > 2:
  	owner_mail = argv[2]
      else:
! 	owner_mail = raw_input(
! 	    "Enter the email of the person running the list: ")
      if len(argv) > 3:
  	list_pw = argv[3]
      else:
--- 75,85 ----
      if len(argv) > 2:
  	owner_mail = argv[2]
      else:
!          owner_mail = joinfields (split (raw_input(        
! 	    "Enter the email of the person running the list: "), 
!             ' '), '\n')
! 
! 
      if len(argv) > 3:
  	list_pw = argv[3]
      else:
***************
*** 132,138 ****
           'requestaddr' : "%s-request@%s" % (list_name, newlist.host_name),
           'hostname'    : newlist.host_name,
           })
!     newlist.SendTextToUser(subject="Your new mailing list",
  			   recipient=owner_mail,
  			   sender='mailman-owner@%s' % newlist.host_name, 
  			   text=text)
--- 136,143 ----
           'requestaddr' : "%s-request@%s" % (list_name, newlist.host_name),
           'hostname'    : newlist.host_name,
           })
!     for admin in splitfields(owner_mail, '\n'):
!        newlist.SendTextToUser(subject="Your new mailing list",
  			   recipient=owner_mail,
  			   sender='mailman-owner@%s' % newlist.host_name, 
  			   text=text)