Patchwork [04,of,10] serve: pass on the repo instad of recreating it in hgweb

login
register
mail settings
Submitter Simon Heimberg
Date March 22, 2013, 1:20 a.m.
Message ID <67fbcd9146e125f8f295.1363915254@lapsi.heimberg.home>
Download mbox | patch
Permalink /patch/1154/
State Accepted
Commit b718999f2e0b8709d05bae5dd7353746a576d3dc
Headers show

Comments

Simon Heimberg - March 22, 2013, 1:20 a.m.
# HG changeset patch
# User Simon Heimberg <simohe@besonet.ch>
# Date 1363886209 -3600
# Node ID 67fbcd9146e125f8f2953e02f455e329a6328fb5
# Parent  105291a2228c1e12990bb13e25924b07e7e5319a
serve: pass on the repo instad of recreating it in hgweb

When we pass on the path to the repo, the repo is created in hgweb. But the
repo is already here, so pass it on.

Patch

diff -r 105291a2228c -r 67fbcd9146e1 mercurial/commands.py
--- a/mercurial/commands.py	Don Mär 21 18:16:48 2013 +0100
+++ b/mercurial/commands.py	Don Mär 21 18:16:49 2013 +0100
@@ -5004,7 +5004,7 @@ 
         if not repo:
             raise error.RepoError(_("there is no Mercurial repository"
                                     " here (.hg not found)"))
-        o = repo.root
+        o = repo
 
     app = hgweb.hgweb(o, baseui=baseui)