mirror of
https://github.com/facebook/sapling.git
synced 2024-10-08 15:57:43 +03:00
Allow list of (virtual, real) or dictionary to be passed to hgwebdir.
This commit is contained in:
parent
19e3a9cdda
commit
05fb9953ac
@ -922,10 +922,16 @@ def server(path, name, templates, address, port, use_ipv6=False,
|
||||
# This is a stopgap
|
||||
class hgwebdir:
|
||||
def __init__(self, config):
|
||||
cp = ConfigParser.SafeConfigParser()
|
||||
cp.read(config)
|
||||
self.repos = cp.items("paths")
|
||||
self.repos.sort()
|
||||
if type(config) == type([]):
|
||||
self.repos = config
|
||||
elif type(config) == type({}):
|
||||
self.repos = config.items()
|
||||
self.repos.sort()
|
||||
else:
|
||||
cp = ConfigParser.SafeConfigParser()
|
||||
cp.read(config)
|
||||
self.repos = cp.items("paths")
|
||||
self.repos.sort()
|
||||
|
||||
def run(self):
|
||||
def header(**map):
|
||||
|
Loading…
Reference in New Issue
Block a user