diff options
| author | mailman | 1998-02-21 19:59:55 +0000 |
|---|---|---|
| committer | mailman | 1998-02-21 19:59:55 +0000 |
| commit | 16d507528471c1182bb375f81b03f5c0e151b718 (patch) | |
| tree | 49bb65c3caf8209e9a03346f52898c49916dd18b | |
| parent | 5947deaf34810d21c3a40d4f372244d1ed9e48a6 (diff) | |
| download | mailman-16d507528471c1182bb375f81b03f5c0e151b718.tar.gz mailman-16d507528471c1182bb375f81b03f5c0e151b718.tar.zst mailman-16d507528471c1182bb375f81b03f5c0e151b718.zip | |
| -rw-r--r-- | Mailman/Archiver.py | 9 | ||||
| -rw-r--r-- | modules/mm_archive.py | 9 |
2 files changed, 16 insertions, 2 deletions
diff --git a/Mailman/Archiver.py b/Mailman/Archiver.py index e2fb4768b..099d44f00 100644 --- a/Mailman/Archiver.py +++ b/Mailman/Archiver.py @@ -10,6 +10,7 @@ class Archiver: # Not configurable self._base_archive_url = os.path.join(mm_cfg.ARCHIVE_URL, self._internal_name) + self.archive_update_frequency = 1 # 0 = never, 1 = daily, 2 = hourly self.archive_volume_frequency = 0 # 0 = yearly, 1 = monthly self.clobber_date = 0 @@ -18,6 +19,10 @@ class Archiver: ('archive', mm_cfg.Toggle, ('No', 'Yes'), 0, 'Archive messages?'), + ('archive_update_frequency', mm_cfg.Number, 3, 0, + "How often should new messages be incorporated? " + "0 for no archival, typically 1 for daily, 2 for hourly"), + ('archive_volume_frequency', mm_cfg.Radio, ('Yearly', 'Monthly'), 0, 'How often should the archive volume go up?'), @@ -60,7 +65,9 @@ class Archiver: # Internal function, don't call this. def ArchiveMail(self, post): - archive_file = open(os.path.join(self._full_path, "archived.mail"), "a+") + archive_file = open(os.path.join(self._full_path, + "archived.mail"), + "a+") archive_mbox = mm_mbox.Mailbox(archive_file) if self.clobber_date: import time diff --git a/modules/mm_archive.py b/modules/mm_archive.py index e2fb4768b..099d44f00 100644 --- a/modules/mm_archive.py +++ b/modules/mm_archive.py @@ -10,6 +10,7 @@ class Archiver: # Not configurable self._base_archive_url = os.path.join(mm_cfg.ARCHIVE_URL, self._internal_name) + self.archive_update_frequency = 1 # 0 = never, 1 = daily, 2 = hourly self.archive_volume_frequency = 0 # 0 = yearly, 1 = monthly self.clobber_date = 0 @@ -18,6 +19,10 @@ class Archiver: ('archive', mm_cfg.Toggle, ('No', 'Yes'), 0, 'Archive messages?'), + ('archive_update_frequency', mm_cfg.Number, 3, 0, + "How often should new messages be incorporated? " + "0 for no archival, typically 1 for daily, 2 for hourly"), + ('archive_volume_frequency', mm_cfg.Radio, ('Yearly', 'Monthly'), 0, 'How often should the archive volume go up?'), @@ -60,7 +65,9 @@ class Archiver: # Internal function, don't call this. def ArchiveMail(self, post): - archive_file = open(os.path.join(self._full_path, "archived.mail"), "a+") + archive_file = open(os.path.join(self._full_path, + "archived.mail"), + "a+") archive_mbox = mm_mbox.Mailbox(archive_file) if self.clobber_date: import time |
