From 68793c2e490bf27c9639633044c8edaae77853b5 Mon Sep 17 00:00:00 2001 From: "Bradley M. Kuhn" Date: Sat, 8 Nov 2014 12:21:10 -0500 Subject: Changes to Mailman Python code for copyleft.org branding. This does not completely fix the branding issues; some patches to the templates in /etc/mailman/en/ will next be required. --- .etckeeper | 43 ++++++++++++++++------------------------- mailman/Defaults.py | 2 +- mailman/htmlformat.py | 51 +++++++++++++++++++++++++++++++++++++++++++++---- 3 files changed, 64 insertions(+), 32 deletions(-) diff --git a/.etckeeper b/.etckeeper index 1eaaa08..8ddd0b4 100755 --- a/.etckeeper +++ b/.etckeeper @@ -698,10 +698,10 @@ maybe chmod 0644 './mailcap' maybe chmod 0644 './mailcap.order' maybe chgrp list './mailman' maybe chmod 0755 './mailman' -maybe chgrp list './mailman/Defaults.py' -maybe chmod 0644 './mailman/Defaults.py' +maybe chmod 0600 './mailman/Defaults.py' maybe chgrp list './mailman/Defaults.py.~1~' maybe chmod 0644 './mailman/Defaults.py.~1~' +maybe chmod 0600 './mailman/Defaults.py.~2~' maybe chmod 0644 './mailman/apache.conf' maybe chmod 0755 './mailman/de' maybe chgrp list './mailman/de/admindbdetails.html' @@ -809,22 +809,17 @@ maybe chgrp list './mailman/en/approve.txt' maybe chmod 0644 './mailman/en/approve.txt' maybe chgrp list './mailman/en/archidxentry.html' maybe chmod 0644 './mailman/en/archidxentry.html' -maybe chgrp list './mailman/en/archidxfoot.html' -maybe chmod 0644 './mailman/en/archidxfoot.html' -maybe chgrp list './mailman/en/archidxhead.html' -maybe chmod 0644 './mailman/en/archidxhead.html' +maybe chmod 0600 './mailman/en/archidxfoot.html' +maybe chmod 0600 './mailman/en/archidxhead.html' maybe chgrp list './mailman/en/archlistend.html' maybe chmod 0644 './mailman/en/archlistend.html' maybe chgrp list './mailman/en/archliststart.html' maybe chmod 0644 './mailman/en/archliststart.html' -maybe chgrp list './mailman/en/archtoc.html' -maybe chmod 0644 './mailman/en/archtoc.html' +maybe chmod 0600 './mailman/en/archtoc.html' maybe chgrp list './mailman/en/archtocentry.html' maybe chmod 0644 './mailman/en/archtocentry.html' -maybe chgrp list './mailman/en/archtocnombox.html' -maybe chmod 0644 './mailman/en/archtocnombox.html' -maybe chgrp list './mailman/en/article.html' -maybe chmod 0644 './mailman/en/article.html' +maybe chmod 0600 './mailman/en/archtocnombox.html' +maybe chmod 0600 './mailman/en/article.html' maybe chgrp list './mailman/en/bounce.txt' maybe chmod 0644 './mailman/en/bounce.txt' maybe chgrp list './mailman/en/checkdbs.txt' @@ -835,42 +830,36 @@ maybe chgrp list './mailman/en/cronpass.txt' maybe chmod 0644 './mailman/en/cronpass.txt' maybe chgrp list './mailman/en/disabled.txt' maybe chmod 0644 './mailman/en/disabled.txt' -maybe chgrp list './mailman/en/emptyarchive.html' -maybe chmod 0644 './mailman/en/emptyarchive.html' +maybe chmod 0600 './mailman/en/emptyarchive.html' maybe chgrp list './mailman/en/headfoot.html' maybe chmod 0644 './mailman/en/headfoot.html' maybe chgrp list './mailman/en/help.txt' maybe chmod 0644 './mailman/en/help.txt' maybe chgrp list './mailman/en/invite.txt' maybe chmod 0644 './mailman/en/invite.txt' -maybe chgrp list './mailman/en/listinfo.html' -maybe chmod 0644 './mailman/en/listinfo.html' +maybe chmod 0600 './mailman/en/listinfo.html' maybe chgrp list './mailman/en/masthead.txt' maybe chmod 0644 './mailman/en/masthead.txt' maybe chgrp list './mailman/en/newlist.txt' maybe chmod 0644 './mailman/en/newlist.txt' maybe chgrp list './mailman/en/nomoretoday.txt' maybe chmod 0644 './mailman/en/nomoretoday.txt' -maybe chgrp list './mailman/en/options.html' -maybe chmod 0644 './mailman/en/options.html' +maybe chmod 0600 './mailman/en/options.html' maybe chgrp list './mailman/en/postack.txt' maybe chmod 0644 './mailman/en/postack.txt' maybe chgrp list './mailman/en/postauth.txt' maybe chmod 0644 './mailman/en/postauth.txt' maybe chgrp list './mailman/en/postheld.txt' maybe chmod 0644 './mailman/en/postheld.txt' -maybe chgrp list './mailman/en/private.html' -maybe chmod 0644 './mailman/en/private.html' +maybe chmod 0600 './mailman/en/private.html' maybe chgrp list './mailman/en/probe.txt' maybe chmod 0644 './mailman/en/probe.txt' maybe chgrp list './mailman/en/refuse.txt' maybe chmod 0644 './mailman/en/refuse.txt' -maybe chgrp list './mailman/en/roster.html' -maybe chmod 0644 './mailman/en/roster.html' +maybe chmod 0600 './mailman/en/roster.html' maybe chgrp list './mailman/en/subauth.txt' maybe chmod 0644 './mailman/en/subauth.txt' -maybe chgrp list './mailman/en/subscribe.html' -maybe chmod 0644 './mailman/en/subscribe.html' +maybe chmod 0600 './mailman/en/subscribe.html' maybe chgrp list './mailman/en/subscribeack.txt' maybe chmod 0644 './mailman/en/subscribeack.txt' maybe chgrp list './mailman/en/unsub.txt' @@ -972,10 +961,10 @@ maybe chgrp list './mailman/es/userpass.txt' maybe chmod 0644 './mailman/es/userpass.txt' maybe chgrp list './mailman/es/verify.txt' maybe chmod 0644 './mailman/es/verify.txt' -maybe chgrp list './mailman/htmlformat.py' -maybe chmod 0644 './mailman/htmlformat.py' +maybe chmod 0600 './mailman/htmlformat.py' +maybe chmod 0600 './mailman/htmlformat.py.~1~' maybe chmod 0644 './mailman/leftover' -maybe chmod 0644 './mailman/mm_cfg.py' +maybe chmod 0600 './mailman/mm_cfg.py' maybe chmod 0755 './mailman/postfix-to-mailman.py' maybe chmod 0755 './mailman/qmail-to-mailman.py' maybe chmod 0644 './mailname' diff --git a/mailman/Defaults.py b/mailman/Defaults.py index 2668310..db73637 100644 --- a/mailman/Defaults.py +++ b/mailman/Defaults.py @@ -57,7 +57,7 @@ No = no = Off = off = False IMAGE_LOGOS = '/doc/mailman/images/' # The name of the Mailman favicon -SHORTCUT_ICON = 'mm-icon.png' +SHORTCUT_ICON = 'copyleft.ico' # Don't change MAILMAN_URL, unless you want to point it at one of the mirrors. MAILMAN_URL = 'http://www.gnu.org/software/mailman/index.html' diff --git a/mailman/htmlformat.py b/mailman/htmlformat.py index d530989..e129ba9 100644 --- a/mailman/htmlformat.py +++ b/mailman/htmlformat.py @@ -309,7 +309,9 @@ class Document(Container): tab = ' ' * indent output.extend([tab, '', - '' + '', + '', + '' ]) if mm_cfg.IMAGE_LOGOS: output.append('' % @@ -334,6 +336,37 @@ class Document(Container): # Language direction direction = Utils.GetDirection(self.language) output.append('dir="%s">' % direction) + output.append(""" + + +
+
+ +
+
+""") # Always do this... output.append(Container.Format(self, indent)) if not self.suppress_head: @@ -632,7 +665,6 @@ GNU_HEAD = 'gnu-head-tiny.jpg' def MailmanLogo(): t = Table(border=0, width='100%') - version = mm_cfg.VERSION mmlink = _("Delivered by Mailman") pylink = _("Python Powered") @@ -650,7 +682,7 @@ def MailmanLogo(): if mm_cfg.SITE_LINK: sitelink = logo(mm_cfg.SITE_LOGO, sitelink, "") - mmlink = Link(MAILMAN_URL, mmlink + _('
version %(version)s')) + mmlink = Link(MAILMAN_URL, mmlink + _('version %(version)s')) pylink = Link(PYTHON_URL, pylink) gnulink = Link(GNU_URL, gnulink) links = [mmlink, pylink, gnulink] @@ -659,7 +691,18 @@ def MailmanLogo(): sitelink = Link(mm_cfg.SITE_URL, sitelink) links.append(sitelink) t.AddRow(links) - return t + return(""" + + + +""" % {'MAILMAN': mmlink.Format()}) +# return t class SelectOptions: -- 1.7.10.4 From 4b6b9e651458acc8f37ddfac5607d39ef78da9b0 Mon Sep 17 00:00:00 2001 From: "Bradley M. Kuhn" Date: Sat, 8 Nov 2014 12:22:41 -0500 Subject: Rebranding changes for copyleft.org to mailman HTML templates. --- mailman/en/archidxfoot.html | 15 ++++++++++++-- mailman/en/archidxhead.html | 32 ++++++++++++++++++++++++++++++ mailman/en/archtoc.html | 43 +++++++++++++++++++++++++++++++++++++++++ mailman/en/archtocnombox.html | 15 ++++++++++++++ mailman/en/article.html | 43 +++++++++++++++++++++++++++++++++++++++++ mailman/en/emptyarchive.html | 43 +++++++++++++++++++++++++++++++++++++++++ mailman/en/listinfo.html | 31 ++++++++++++++++++++++++++++- mailman/en/options.html | 31 +++++++++++++++++++++++++++++ mailman/en/private.html | 43 +++++++++++++++++++++++++++++++++++++++++ mailman/en/roster.html | 31 +++++++++++++++++++++++++++++ mailman/en/subscribe.html | 35 ++++++++++++++++++++++++++++++++- 11 files changed, 358 insertions(+), 4 deletions(-) diff --git a/mailman/en/archidxfoot.html b/mailman/en/archidxfoot.html index 0b0a420..e067a37 100644 --- a/mailman/en/archidxfoot.html +++ b/mailman/en/archidxfoot.html @@ -15,7 +15,18 @@


- This archive was generated by - Pipermail %(version)s. + +
+
+ + +
+
+ + diff --git a/mailman/en/archidxhead.html b/mailman/en/archidxhead.html index 2227dfd..15bf066 100644 --- a/mailman/en/archidxhead.html +++ b/mailman/en/archidxhead.html @@ -1,11 +1,43 @@ + + + The %(listname)s %(archive)s Archive by %(archtype)s %(encoding)s + + +
+
+ +

%(archive)s Archives by %(archtype)s