mirror of
ssh://git.janware.com/srv/git/janware/proj/jw-python
synced 2026-01-15 09:53:32 +01:00
Config: Add .root
Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
parent
18117e4590
commit
7cd94fa3db
1 changed files with 6 additions and 0 deletions
|
|
@ -113,6 +113,12 @@ class Config(): # export
|
||||||
def parent(self):
|
def parent(self):
|
||||||
return self.__parent
|
return self.__parent
|
||||||
|
|
||||||
|
@property
|
||||||
|
def root(self):
|
||||||
|
if self.__parent is None:
|
||||||
|
return self
|
||||||
|
return self.__parent.root
|
||||||
|
|
||||||
def set(self, key: str, val):
|
def set(self, key: str, val):
|
||||||
self.__conf[key] = val
|
self.__conf[key] = val
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue