Dwayne Phillips wrote: > >I have one problem, this resides on a shared machine. Any way to script it >for a particular client? > >-----Original Message----- >From: Mark Sapiro [mailto:[EMAIL PROTECTED] >Sent: Saturday, March 12, 2005 7:37 AM >To: [EMAIL PROTECTED]; mailman-users@python.org >Subject: Re: [Mailman-Users] Mailman Question > >Dwayne Phillips wrote: > >>Is there anyway to schedule digest emails? >> >>I could use a timer to send emails once a week at a particular time.
<previous response snipped> Assuming you have access to the command line, you can do the following. 1) set digest_send_periodic the specific list's Digest options page to No 2) make a new script by modifying cron/senddigests as follows: --- senddigests 2005-02-06 14:27:23.968750000 -0800 +++ new_senddigests 2005-03-15 12:41:54.765625000 -0800 @@ -28,6 +28,8 @@ --listname=listname Send the digest for the given list only, otherwise the digests for all lists are sent out. + If this option is specified the list's digest_send_periodic flag is + ignored. """ import sys @@ -69,6 +71,7 @@ usage(1) listnames = [] + unconditional = 0 for opt, arg in opts: if opt in ('-h', '--help'): usage(0) @@ -77,10 +80,12 @@ if not listnames: listnames = Utils.list_names() + else: + unconditional = 1 for listname in listnames: mlist = MailList.MailList(listname, lock=0) - if mlist.digest_send_periodic: + if mlist.digest_send_periodic or unconditional: mlist.Lock() try: mlist.send_digest_now() 3) Set up a cron or whatever to run the command /usr/bin/python -S $prefix/cron/new_senddigests --listname=<listname> where /usr/bin/python may need to be adjusted, $prefix is the path to your mailman installation and <listname> is the name of the list, on the desired schedule. 4) You may want to set digest_size_threshhold for the list to a very large number if you don't want any digest sends triggered by size. -- Mark Sapiro <[EMAIL PROTECTED]> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan ------------------------------------------------------ Mailman-Users mailing list Mailman-Users@python.org http://mail.python.org/mailman/listinfo/mailman-users Mailman FAQ: http://www.python.org/cgi-bin/faqw-mm.py Searchable Archives: http://www.mail-archive.com/mailman-users%40python.org/ Unsubscribe: http://mail.python.org/mailman/options/mailman-users/archive%40jab.org Security Policy: http://www.python.org/cgi-bin/faqw-mm.py?req=show&file=faq01.027.htp