MCPcopy Index your code
hub / github.com/python/cpython / CreateConfigHandlers

Method CreateConfigHandlers

Lib/idlelib/config.py:169–177  ·  view source on GitHub ↗

Populate default and user config parser dictionaries.

(self)

Source from the content-addressed store, hash-verified

167 self.LoadCfgFiles()
168
169 def CreateConfigHandlers(self):
170 "Populate default and user config parser dictionaries."
171 idledir = os.path.dirname(__file__)
172 self.userdir = userdir = '' if idlelib.testing else self.GetUserCfgDir()
173 for cfg_type in self.config_types:
174 self.defaultCfg[cfg_type] = IdleConfParser(
175 os.path.join(idledir, f'config-{cfg_type}.def'))
176 self.userCfg[cfg_type] = IdleUserConfParser(
177 os.path.join(userdir or '#', f'config-{cfg_type}.cfg'))
178
179 def GetUserCfgDir(self):
180 """Return a filesystem directory for storing user config files.

Callers 2

__init__Method · 0.95

Calls 5

GetUserCfgDirMethod · 0.95
IdleConfParserClass · 0.85
IdleUserConfParserClass · 0.85
dirnameMethod · 0.45
joinMethod · 0.45

Tested by 1