configparserplus
If you have to multiple .ini files (for instance, when dealing with Pyramid's settings) you probably realized that the lack of a decent hierarchy between settings files just sucks.
configparserplus allows you to use Jinja2 templating language on your .ini files so you don't need to ctrl-C, ctrl-V your settings in your N config files. Seriously, never do it again. Just. Never.
Usage:
Just replace:
from configparser import ConfigParser # `from ConfigParser import ConfigParser` in Python2
config = ConfigParser()
... to:
from configparserplus import ConfigParserPlus
config = ConfigParserPlus()
... and refactor your .ini files to use Jinja stuff (such as templates inheritance)
For more details, please check these examples.
Ah! Configparserplus works normally on non-jinja (boring, regular) .ini files - so you can just replace it and refactor bit by bit.
Development:
Run linter:
pip install -r requirements_dev.txt
isort -rc .
tox -e lint
Run tests via tox:
pip install -r requirements_dev.txt
tox
Release a new major/minor/patch version:
pip install -r requirements_dev.txt
bump2version <PART> # <PART> can be either 'patch' or 'minor' or 'major'
Upload to PyPI:
pip install -r requirements_dev.txt
python setup.py sdist bdist_wheel
python -m twine upload dist/*
Contributing:
Please open issues if you see one, or create a pull request when possible. In case of a pull request, please consider the following:
- Respect the line length (132 characters)
- Write automated tests
- Run
toxlocally so you can see if everything is green (including linter and other python versions)
Metadata
Release files for configparserplus 0.0.6
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| configparserplus-0.0.6.tar.gz | 3.9 kB | Without provenance | Details for configparserplus-0.0.6.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| configparserplus-0.0.6-py2-none-any.whl | Python 2 | none | any | Details for configparserplus-0.0.6-py2-none-any.whl |
Total release size: 8.4 kB
Release files / configparserplus-0.0.6.tar.gz
| Download URL | configparserplus-0.0.6.tar.gz |
|---|---|
| Size | 3.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2562ed433789d56f9a0d804533ff68c9223c66c44ddbd61d3cf69e48c66e02bc
|
|
BLAKE2b-256 checksum How to use checksums |
9bf703bc7b8e5d36e39beb2d4a3fd1819da47cacec35a068a61cac971f7afc37
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/2.7.17
|
Release files / configparserplus-0.0.6-py2-none-any.whl
| Download URL | configparserplus-0.0.6-py2-none-any.whl |
|---|---|
| Size | 4.5 kB |
| Tags | Python 2 |
|
SHA-256 checksum How to use checksums |
6c092bba548a6a0cb8f671b8a591aa7fd96d5dd99c3f34adc742e77e15131f08
|
|
BLAKE2b-256 checksum How to use checksums |
7f5e939ea09c8c647d9860c5b445d70c85b128e3f5c11a0d96ace9d13db5f1ae
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/2.7.17
|
Security for configparserplus 0.0.6
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.