##// END OF EJS Templates
hgweb: add baseui to hgweb entrypoint
Matt Mackall -
r10994:c12a57c1 default
parent child Browse files
Show More
@@ -8,8 +8,8 b''
8 8
9 9 import hgweb_mod, hgwebdir_mod
10 10
11 def hgweb(repo, name=None):
12 return hgweb_mod.hgweb(repo, name=name)
11 def hgweb(repo, name=None, baseui=None):
12 return hgweb_mod.hgweb(repo, name=name, baseui=baseui)
13 13
14 14 def hgwebdir(config, baseui=None):
15 15 return hgwebdir_mod.hgwebdir(config, baseui=baseui)
@@ -21,9 +21,12 b' perms = {'
21 21 }
22 22
23 23 class hgweb(object):
24 def __init__(self, repo, name=None):
24 def __init__(self, repo, name=None, baseui=None):
25 25 if isinstance(repo, str):
26 u = ui.ui()
26 if baseui:
27 u = baseui.copy()
28 else:
29 u = ui.ui()
27 30 u.setconfig('ui', 'report_untrusted', 'off')
28 31 u.setconfig('ui', 'interactive', 'off')
29 32 self.repo = hg.repository(u, repo)
General Comments 0
You need to be logged in to leave comments. Login now