A customized way to use config
Usage
From string
from r_config import RConfig
rc = RConfig()
str_yaml = """
example1:
id: 2
name: 'Ramin'
# comment to test
example2:
sub1:
p1: 2.2
sub2: 'test_1'
"""
rc.update_from_str(str_yaml)
From file
from r_config import RConfig
from pathlib import Path
rc = RConfig()
path = Path('/path/to/config.yaml')
rc.update_from_file(path)
From dict
from r_config import RConfig
r_dict = {'a': 10, 'b': 'salam', 'f': {'p': 2, 'q': 3}}
rc = RConfig(r_dict)
Metadata
Release files for r-config 0.4.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| r_config-0.4.2.tar.gz | 2.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| r_config-0.4.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 5.0 kB
Release files / r_config-0.4.2.tar.gz
| Download URL | r_config-0.4.2.tar.gz |
|---|---|
| Size | 2.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
83f3112144f563bc49c3c4a5d9cb31a7aae1ede12e4062d1bfbc4d1c7ad64561
|
|
BLAKE2b-256 checksum How to use checksums |
b40e0d614a2a4d819727433411577eca30369513b42a2ac1a494114722250cca
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.9.19
|
Release files / r_config-0.4.2-py3-none-any.whl
| Download URL | r_config-0.4.2-py3-none-any.whl |
|---|---|
| Size | 2.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9030c3d589d334614dcaabd818fbbebfe7cd0e5a00c51dc7cf64143d49dd294b
|
|
BLAKE2b-256 checksum How to use checksums |
55db05bdbcfeda23a64dce09bab5688134d03450bee61cc6261b021547468f20
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.9.19
|