From: fred Date: Tue, 26 Mar 2002 23:57:46 +0000 (+0000) Subject: lilypond-1.4.2 X-Git-Tag: release/1.5.59~1214 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=9af96645d57b5eca0acc5058bb21e39dc2fbe3f9;p=lilypond.git lilypond-1.4.2 --- diff --git a/stepmake/bin/add-html-footer.py b/stepmake/bin/add-html-footer.py index a3aa23133a..6a08f29e0a 100644 --- a/stepmake/bin/add-html-footer.py +++ b/stepmake/bin/add-html-footer.py @@ -38,10 +38,12 @@ default_footer = r"""
Please take me back to the index of @PACKAGE_NAME@ """ -built = r"""
-This page was built from @PACKAGE_NAME@-@PACKAGE_VERSION@ by -

@GCOS@ <@MAIL_ADDRESS@>, -@LOCALTIME@.

""" +built = r"""


+

+This page was built from @PACKAGE_NAME@-@PACKAGE_VERSION@ by
+
+

@GCOS@ <@MAIL_ADDRESS@>, +@LOCALTIME@.
""" def gulp_file (f): @@ -108,7 +110,10 @@ def set_gcos (): pw = ntpwd.getpwname(os.environ['USERNAME']) else: import pwd - pw = pwd.getpwuid (os.getuid()); + if os.environ.has_key('FAKEROOTKEY'): + pw = pwd.getpwnam (os.environ['LOGNAME']) + else: + pw = pwd.getpwuid (os.getuid()) f = pw[4] f = string.split (f, ',')[0] @@ -129,8 +134,8 @@ top_url = os.path.dirname (index_url) + "/" header = compose (default_header, header_file) footer = compose (default_footer, footer_file) + built -header_tag = '' -footer_tag = '' +header_tag = '' +footer_tag = '' def do_file (f): s = gulp_file (f) @@ -142,10 +147,10 @@ def do_file (f): m = re.search (r'\*\*\*', changes) if m: changes = changes[:m.start (0)] - s = re.sub ('top_of_ChangeLog', '\n'+ changes + '\n\n', s) + s = re.sub ('top_of_ChangeLog', '
\n'+ changes  + '\n
\n', s) if re.search (header_tag, s) == None: - body = '' + body = '' s = re.sub ('(?i)', body, s) if re.search ('(?i)]*>', body + header, s, 1) @@ -154,10 +159,14 @@ def do_file (f): else: s = header + s - s = header_tag + s + s = header_tag + '\n' + s + + if re.search ('(?i)\n' + s = doctype + s if re.search (footer_tag, s) == None: - s = s + footer_tag + s = s + footer_tag + '\n' if re.search ('(?i)', footer + '', s, 1)