Show More
@@ -101,17 +101,20 class hgwebzc(hgweb_mod.hgweb): | |||
|
101 | 101 | def __init__(self, repo, name=None): |
|
102 | 102 | super(hgwebzc, self).__init__(repo, name) |
|
103 | 103 | name = self.reponame or os.path.basename(repo.root) |
|
104 | path = self.repo.ui.config("web", "prefix", "").strip('/') | |
|
104 | 105 | desc = self.repo.ui.config("web", "description", name) |
|
105 |
publish(name, desc, |
|
|
106 | publish(name, desc, path, int(repo.ui.config("web", "port", 8000))) | |
|
106 | 107 | |
|
107 | 108 | class hgwebdirzc(hgwebdir_mod.hgwebdir): |
|
108 | def run(self): | |
|
109 | def __init__(self, conf, baseui=None): | |
|
110 | super(hgwebdirzc, self).__init__(conf, baseui) | |
|
111 | prefix = self.ui.config("web", "prefix", "").strip('/') + '/' | |
|
109 | 112 | for r, p in self.repos: |
|
110 | 113 | u = self.ui.copy() |
|
111 | 114 | u.readconfig(os.path.join(p, '.hg', 'hgrc')) |
|
112 | 115 | n = os.path.basename(r) |
|
113 | publish(n, "hgweb", p, int(u.config("web", "port", 8000))) | |
|
114 | return super(hgwebdirzc, self).run() | |
|
116 | path = (prefix + r).strip('/') | |
|
117 | publish(n, "hgweb", path, int(u.config("web", "port", 8000))) | |
|
115 | 118 | |
|
116 | 119 | # listen |
|
117 | 120 |
General Comments 0
You need to be logged in to leave comments.
Login now