comparison mercurial/hgweb/hgwebdir_mod.py @ 16754:d94c470c3deb

hgweb: use ui.nontty to disable all cooked I/O
author Matt Mackall <mpm@selenic.com>
date Sun, 20 May 2012 14:37:22 -0500
parents 287f76b3f502
children 5a9acb0b2086
comparison
equal deleted inserted replaced
16753:9cca7b70f8df 16754:d94c470c3deb
95 if self.baseui: 95 if self.baseui:
96 u = self.baseui.copy() 96 u = self.baseui.copy()
97 else: 97 else:
98 u = ui.ui() 98 u = ui.ui()
99 u.setconfig('ui', 'report_untrusted', 'off') 99 u.setconfig('ui', 'report_untrusted', 'off')
100 u.setconfig('ui', 'interactive', 'off') 100 u.setconfig('ui', 'nontty', 'true')
101 101
102 if not isinstance(self.conf, (dict, list, tuple)): 102 if not isinstance(self.conf, (dict, list, tuple)):
103 map = {'paths': 'hgweb-paths'} 103 map = {'paths': 'hgweb-paths'}
104 if not os.path.exists(self.conf): 104 if not os.path.exists(self.conf):
105 raise util.Abort(_('config file %s not found!') % self.conf) 105 raise util.Abort(_('config file %s not found!') % self.conf)