mercurial/hgweb/hgweb_mod.py
changeset 37514 034a422aeaff
parent 37512 aac97d043e6d
child 37746 b29f490eb904
equal deleted inserted replaced
37513:40a7c1dd2df9 37514:034a422aeaff
   126     def configlist(self, section, name, default=uimod._unset, untrusted=True):
   126     def configlist(self, section, name, default=uimod._unset, untrusted=True):
   127         return self.repo.ui.configlist(section, name, default,
   127         return self.repo.ui.configlist(section, name, default,
   128                                        untrusted=untrusted)
   128                                        untrusted=untrusted)
   129 
   129 
   130     def archivelist(self, nodeid):
   130     def archivelist(self, nodeid):
   131         allowed = self.configlist('web', 'allow_archive')
   131         return webutil.archivelist(self.repo.ui, nodeid)
   132         for typ, spec in webutil.archivespecs.iteritems():
       
   133             if typ in allowed or self.configbool('web', 'allow%s' % typ):
       
   134                 yield {'type': typ, 'extension': spec[2], 'node': nodeid}
       
   135 
   132 
   136     def templater(self, req):
   133     def templater(self, req):
   137         # determine scheme, port and server name
   134         # determine scheme, port and server name
   138         # this is needed to create absolute urls
   135         # this is needed to create absolute urls
   139         logourl = self.config('web', 'logourl')
   136         logourl = self.config('web', 'logourl')