diff options
author | bwarsaw <> | 2006-09-17 18:16:07 +0000 |
---|---|---|
committer | bwarsaw <> | 2006-09-17 18:16:07 +0000 |
commit | 34d6ece8a454e5d1d027ed106ba039a0a88db36d (patch) | |
tree | 6dc6f8711b20124ce38491300d5fb95e1c022206 /admin/bin/mm2do | |
parent | b7f0fb3c888c1d331c2239fba0b8332a3bf240f2 (diff) | |
download | mailman2-34d6ece8a454e5d1d027ed106ba039a0a88db36d.tar.gz mailman2-34d6ece8a454e5d1d027ed106ba039a0a88db36d.tar.xz mailman2-34d6ece8a454e5d1d027ed106ba039a0a88db36d.zip |
Copy the mm21 admin directory out of the mm21 branch. We'll svn
external the latter to get that back into the release, but I really
don't want to maintain multiple copies of the web pages.
Diffstat (limited to 'admin/bin/mm2do')
-rwxr-xr-x | admin/bin/mm2do | 76 |
1 files changed, 0 insertions, 76 deletions
diff --git a/admin/bin/mm2do b/admin/bin/mm2do deleted file mode 100755 index e6b7a534..00000000 --- a/admin/bin/mm2do +++ /dev/null @@ -1,76 +0,0 @@ -#! /usr/bin/env python -# -# Copyright (C) 1998,1999,2000,2001,2002 by the Free Software Foundation, Inc. -# -# This program is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License -# as published by the Free Software Foundation; either version 2 -# of the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - -"""Generate the todo.ht file from the plain-text TODO file.""" - -import sys - -infp = open(sys.argv[1]) -outfp = open(sys.argv[2], 'w') - -SPACE = ' ' - -print >> outfp, 'Title: The Mailman Wishlist\n' - -def dumpsection(header, items, hasitems): - # We're looking at a header - if header: - # output the previous section - print >> outfp, '<h3>', header, '</h3>' - if hasitems: - print >> outfp, '<ul>' - for item in items: - if item: - print >> outfp, ' <li>', SPACE.join(item) - print >> outfp, '</ul>' - else: - for item in items: - print >> outfp, SPACE.join(item), '<p>' - - - -header = '' -items = [['']] -hasitems = False -inpreamble = True -while True: - line = infp.readline() - if not line or line[0] == '\f': - break - # Skip the legalese preamble - if inpreamble: - if line.strip(): - continue - else: - inpreamble = False - if not line[0].isspace(): - dumpsection(header, items, hasitems) - header = line - items = [[]] - continue - # find out what the first non-ws character on the line is - line = line.lstrip() - if line and line[0] == '-': - items.append([line[2:-1]]) - hasitems = True - else: - if not line: - continue - items[-1].append(line) - -dumpsection(header, items, hasitems) |