diff options
| -rwxr-xr-x | cron/senddigests | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/cron/senddigests b/cron/senddigests new file mode 100755 index 000000000..4acc7db98 --- /dev/null +++ b/cron/senddigests @@ -0,0 +1,23 @@ +#!/usr/local/bin/python +# +# This script gets called by cron. +# It goes through all the lists, dispatching the digests for those that have +# digest_send_periodic set. + +import sys, os + +sys.path.append('/home/mailman/mailman/modules') + +import maillist, mm_cfg, mm_message, mm_utils + +def main(): + + for name in mm_utils.list_names(): + list = maillist.MailList(name) + list.Unlock() + if list.digest_send_periodic: + # Send if there are any messages pending. + list.SendDigestIfAny() + +if __name__ == "__main__": + main() |
