blob: c6cd9f9dd135388ea5f16d62673f3a14c74ffd02 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
Configlib
=========
An easy python config library. Manage multiple configuration environments and complex nested configurations with ease.
Examples
--------
```json
{
"config_var": "jo",
"other_var": 3,
"subConfig": {
"subconfigvar": 10
}
}
```
```py
from configlib import BaseConfig
class SubConfig(object):
subconfigvar: int
class Config(BaseConfig):
config_var: str
other_var: int
subConfig: SubConfig
# Usage
config = Config.get_instance()
config.config_var # "jo"
config.SubConfig.subconfigvar # 10
```
Other Features
--------------
Having multiple config environments inheriting properties from each other, loading data from environment variables, etc.
|