hgweb: support multiple directories for the same path

[paths]
/dir = /path/1/*, /path/2/*
This commit is contained in:
timeless 2011-03-16 03:06:57 +01:00
parent 56241a1f0c
commit 81c1d7fc8b

View File

@ -77,7 +77,10 @@ class hgwebdir(object):
if not os.path.exists(self.conf):
raise util.Abort(_('config file %s not found!') % self.conf)
u.readconfig(self.conf, remap=map, trust=True)
paths = u.configitems('hgweb-paths')
paths = []
for name, ignored in u.configitems('hgweb-paths'):
for path in u.configlist('hgweb-paths', name):
paths.append((name, path))
elif isinstance(self.conf, (list, tuple)):
paths = self.conf
elif isinstance(self.conf, dict):