Code

Ran it through pychecker, made fixes
[roundup.git] / roundup / templatebuilder.py
index cbbd0bf8a98da3168990a1c96b808e1c51d0c422..79b1f1bbb880f464cc13292ca023f4dd0e547dd0 100644 (file)
 # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
 # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
 # 
-# $Id: templatebuilder.py,v 1.12 2001-11-14 21:35:21 richard Exp $
+# $Id: templatebuilder.py,v 1.14 2002-02-05 09:59:05 grubert Exp $
 import errno, re
 
+__doc__ = """
+Collect template parts and create instance template files.
+"""
+
 preamble = """ 
 # Do Not Edit (Unless You Want To)
-# This file automagically generated by roundup.htmldata.makeHtmlBase
+# This file automagically generated by roundup.templatebuilder.makeHtmlBase
 # 
 """
 
@@ -37,7 +41,7 @@ def makeHtmlBase(templateDir):
     for file in filelist:
         # skip the backup files created by richard's vim
         if file[-1] == '~': continue
-        mangled_name = os.path.basename(re.sub(r'\.', 'DOT', file))
+        mangled_name = os.path.basename(file).replace('.','DOT')
         fd.write('%s = """'%mangled_name)
         fd.write(re.sub(r'\$((Id|File|Log).*?)\$', r'dollar\1dollar',
             open(file).read(), re.I))
@@ -85,6 +89,12 @@ if __name__ == "__main__":
 
 #
 # $Log: not supported by cvs2svn $
+# Revision 1.13  2001/11/22 15:46:42  jhermann
+# Added module docstrings to all modules.
+#
+# Revision 1.12  2001/11/14 21:35:21  richard
+#  . users may attach files to issues (and support in ext) through the web now
+#
 # Revision 1.11  2001/08/07 00:24:42  richard
 # stupid typo
 #