##// END OF EJS Templates
ui: add a "config_default" method...
marmoute -
r46893:b9b37418 default
parent child Browse files
Show More
@@ -673,6 +673,18 b' class ui(object):'
673 673 )
674 674 return value
675 675
676 def config_default(self, section, name):
677 """return the default value for a config option
678
679 The default is returned "raw", for example if it is a callable, the
680 callable was not called.
681 """
682 item = self._knownconfig.get(section, {}).get(name)
683
684 if item is None:
685 raise KeyError((section, name))
686 return item.default
687
676 688 def configsuboptions(self, section, name, default=_unset, untrusted=False):
677 689 """Get a config option and all sub-options.
678 690
General Comments 0
You need to be logged in to leave comments. Login now