Mercurial > hg
diff mercurial/hgweb/hgwebdir_mod.py @ 9363:8635b33eaade
hgweb: add web.descend configuration variable
author | Dirkjan Ochtman <dirkjan@ochtman.nl> |
---|---|
date | Wed, 19 Aug 2009 12:47:04 +0200 |
parents | f6eb03027411 |
children | a235644a0b93 |
line wrap: on
line diff
--- a/mercurial/hgweb/hgwebdir_mod.py Tue Aug 18 13:59:30 2009 +0200 +++ b/mercurial/hgweb/hgwebdir_mod.py Wed Aug 19 12:47:04 2009 +0200 @@ -198,12 +198,17 @@ sortdefault = 'name', False def entries(sortcolumn="", descending=False, subdir="", **map): + rows = [] parity = paritygen(self.stripecount) + descend = self.ui.configbool('web', 'descend', True) for name, path in self.repos: + if not name.startswith(subdir): continue name = name[len(subdir):] + if not descend and '/' in name: + continue u = self.ui.copy() try: