diff options
| author | cotton | 1998-11-06 12:17:05 +0000 |
|---|---|---|
| committer | cotton | 1998-11-06 12:17:05 +0000 |
| commit | b16b85131c31e9abfd2bbcbc31521569d98dee44 (patch) | |
| tree | b88815ac9513d981234b2eec833c5faa2efcd2ef | |
| parent | 2960ab11da67918cab99cd2e19b329568c9bd4f5 (diff) | |
| download | mailman-b16b85131c31e9abfd2bbcbc31521569d98dee44.tar.gz mailman-b16b85131c31e9abfd2bbcbc31521569d98dee44.tar.zst mailman-b16b85131c31e9abfd2bbcbc31521569d98dee44.zip | |
update_to_10b6:
made it remove Archiver.py(c),Hyper*.py(c), pipermail.py(c) from
$prefix/Mailman if they're there.
made it rename $prefix/templates/<listname>/* to
$prefix/<listname> only if wouldn't overwrite anything
UPGRADING: changed "you will have to move" to "make update moves",
added note about archived articles from before when
Archiving stuff was in it's own dir.
scott
| -rw-r--r-- | UPGRADING | 11 | ||||
| -rwxr-xr-x | bin/update | 45 |
2 files changed, 52 insertions, 4 deletions
@@ -47,7 +47,16 @@ Hopefully, this will help resolve any problems you are having. can configure mailman to do one, both, or neither. please see $prefix/Mailman/Defaults.py for details. -- If upgrading from version 1.0b4 or earlier, you will have to move + There was a short period of time when the CVS sources archiving code + was not organized into its own package. The pickled articles in the + archives that were placed into archives during this period stored + the path to the module HyperArch, but that module has moved. You + can quick fix this by running + + ln -s $prefix/Mailman/Archiver/HyperArch.py \ + $prefix/Mailman/HyperArch.py + +- If upgrading from version 1.0b4 or earlier, "make update" moves list-specific templates. For each list, move $prefix/templates/<listname>/* to $prefix/lists/<listname>. Please reference the generic templates in $prefix/templates to see if any diff --git a/bin/update b/bin/update index 9078a44b5..1c7320155 100755 --- a/bin/update +++ b/bin/update @@ -129,7 +129,25 @@ script. l.archive_directory = makeabs('archives/private/%s' % (list)) l.private_archive_file_dir = makeabs('archives/private/%s.mbox' % (list)) l.Save() - + # + # check to see if pre-b4 list-specific templates are around + # and move them to the new place if there's not already + # a new one there + # + tmpl_dir = os.path.join(Mailman.mm_cfg.PREFIX, "templates") + list_dir = os.path.join(Mailman.mm_cfg.PREFIX, "lists") + b4_tmpl_dir = os.path.join(tmpl_dir, l._internal_name) + new_tmpl_dir = os.path.join(list_dir, l._internal_name) + if os.path.exists(b4_tmpl_dir): + print "- This list looks like it might have <= b4 list templates around" + for f in os.listdir(b4_tmpl_dir): + o_tmpl = os.path.join(b4_tmpl_dir, f) + n_tmpl = os.path.join(new_tmpl_dir, f) + if not os.path.exists(n_tmpl): + os.rename(o_tmpl, n_tmpl) + print "- moved %s to %s" % (o_tmpl, n_tmpl) + else: + print "- both %s and %s exist, leaving untouched" % (o_tmpl, n_tmpl) # # this function is passed to os.path.walk @@ -146,8 +164,26 @@ def archive_path_fixer(unused_arg, dir, files): elif os.path.isfile(abs): os.chmod(abs, 0664) +def remove_old_sources(module): + src = "%s/Mailman/%s.py" % (Mailman.mm_cfg.PREFIX, + module) + pyc = src + "c" + if os.path.exists(src): + print "removing", src + try: + os.unlink(src) + except os.error, rest: + print "Warning: couldn't remove", src, "--", str(rest) + if os.path.exists(pyc): + try: + os.unlink(pyc) + except os.error, rest: + print "couldn't remove old file", pyc, "--", str(rest) + if __name__ == '__main__': + for mods in ("Archiver", "HyperArch", "HyperDatabase", "pipermail"): + remove_old_sources(module) lists = list_names() if not lists: print "no lists == nothing to do, exiting" @@ -162,8 +198,11 @@ if __name__ == '__main__': os.path.walk("%s/public_html/archives" % Mailman.mm_cfg, archive_path_fixer, "") print "done" - - for list in lists: print 'Updating mailing list: ', list dolist(list) + + + + + |
