hg site extension
 
(Arne Babenhauserheide)
2011-10-20: link commits and src listings.

link commits and src listings.

diff --git a/static.py b/static.py
--- a/static.py
+++ b/static.py
@@ -71,7 +71,7 @@ templates = {
     "foot": "</body></html>",
     "screenstyle": """ """,
     "printstyle": """ """,
-    "manifesthead": """<h2>Commit: {hex} </h2>
+    "manifesthead": """<h2>Commit: <a href='../../commit/{hex}.html'>{hex}</a></h2>
 <p>{desc}</p><p>{user}</p>
     <h2>Files in this revision</h2>"""
 
@@ -171,7 +171,7 @@ def writecommits(ui, repo, target, name,
         os.makedirs(commit)
 
     t = cmdutil.changeset_templater(ui, repo, patch=False, diffopts=None, mapfile=None, buffered=False)
-    t.use_template("""<div style='float: right; padding-left: 0.5em'><em>({author|person})</em></div><strong> {date|shortdate}: <a href='../commit/{node}.html'>{desc|strip|fill68|firstline}</a> <span style='font-size: xx-small'>{branches} {tags}</span><p>{desc|escape}</p>""")
+    t.use_template("""<div style='float: right; padding-left: 0.5em'><em>({author|person})</em></div><strong> {date|shortdate}: <a href='../src/{node}/'>{desc|strip|fill68|firstline}</a> <span style='font-size: xx-small'>{branches} {tags}</span><p>{desc|escape}</p>""")
     for c in range(len(repo.changelog)):
         ctx = repo.changectx(str(c))
         cpath = join(commit, ctx.hex() + ".html")