Create generic any easy way to manage Configs for your project
Project description
pip install cornflakes
pip install git+https://github.com/semmjon/cornflakes
Information
This package was created by starting C ++ methods to incorporate into my python implementations. To make things easier for me, lightweight public libraries were included (especially to carry out string operations):
hash-library
strtk
rapidjson
Features:
- The following features have currently been implemented:
- config management system
based on dataclass
alternative Implementation for pydantic (BaseSettings)
ini support files by a lightweight and fast parser (-> ini_load)
yaml support (based on PyYAML)
environment variables
(future) support json (based on orjson)
- command line interface management
method: click_cli (decorator)
based on click and rich
easy to use and start with
- eval_type
method to parse strings in python-types e.g. int | bool | timestamp
- simple_hmac
vectorized c++ hmac implementation
- default_ca_path
python function to find a default ssl / ca certificate path
Currently, the package is tested for Linux, Mac and Windows
Development
Prerequisites
A compiler with C++17 support
Pip 10+ or CMake >= 3.4 (or 3.8+ on Windows, which was the first version to support VS 2015)
Python 3.8+
doxygen
cppcheck
clang-tools-extra or clang-tidy
Commands
Just clone this repository and pip install. Note the --recursive option which is needed for the pybind11 submodule:
git clone --recursive https://gitlab.blubblub.tech/sgeist/cornflakes.git
Install the package using makefiles:
make install
Build dist using makefiles:
make dist
Run tests (pytest) using makefiles:
make test
Run all tests using makefiles:
make test-all
Run lint using makefiles:
make lint
Create dev venv:
python -m venv .venv
source .venv/bin/activate
pip install cookietemple ninja pre-commit poetry
Bump Version using cookietemple:
cookietemple bump-version "<version(e.g 0.0.1)>"
Run lint using cookietemple:
cookietemple lint .
Install pre-commit:
pre-commit install
Update pre-commit:
pre-commit update -a
Run pre-commit:
pre-commit run -a
Publish
Its not recommended publish manually (use git-ci or github workflows instead).
make publish
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Hashes for cornflakes-3.1.2-cp311-cp311-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a35f64a997e7984a3ca1cb20c7a05798d5882705f8596377b66a203e2774c0eb |
|
MD5 | 96d953298b6f75fd61f442184a058755 |
|
BLAKE2b-256 | 650a257b75f1a5add9ac3e47d9bc75bd4df383a096e3b10921670fbadf08994f |
Hashes for cornflakes-3.1.2-cp311-cp311-manylinux_2_35_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | aba3582d6bdf498651880647f2571aa612391f93028d58368ffa6519932f1993 |
|
MD5 | 026a9e6c8524d94cd6f49a686af7248f |
|
BLAKE2b-256 | a65800f1b58ce668cdf037ae3d4efec17f995030805c3ace5f7c2329cb6ab29a |
Hashes for cornflakes-3.1.2-cp311-cp311-macosx_10_15_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9d7aab21bc768e6d77fc042b8d9bf13d6bc997507984c4f053c8ac8636395685 |
|
MD5 | 09c1dadeb18aad79d4ec3c155b839e68 |
|
BLAKE2b-256 | c1c8aff6ae17b395e6a1199f6f84dcb0af5bb06360b09d8af4c2217d655ce522 |
Hashes for cornflakes-3.1.2-cp310-cp310-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c8eb64a614ca0828d5a6c61610f666260b327e1584e02335987290494203b733 |
|
MD5 | a3f4177db94f7ddeafdaa3dbb55a80fc |
|
BLAKE2b-256 | e5402f4f9c6f67082af2a75011fccae6fee8cc3e02ecefd8aa721cb9c38ce1c4 |
Hashes for cornflakes-3.1.2-cp310-cp310-manylinux_2_35_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | abc2600ee75d4e3c1b1f45a7b5c3c230b1427656ed4bcdf88e80fc45bf98833b |
|
MD5 | 41adc8a2bcdad75d2dd5db940f3dca6e |
|
BLAKE2b-256 | 1e37fcff1743561b30561ff22ac3384c0964bf6f7866d4980b87fe2d12229f17 |
Hashes for cornflakes-3.1.2-cp310-cp310-macosx_10_15_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3b2825092c1a935e65ccefde30bfcf4b76b21d15f848a855abb39f980f7c4f82 |
|
MD5 | 2903945924b26c43a05bd725fe32d1e0 |
|
BLAKE2b-256 | 36adda3ed378c4ae67126f7b8ace9d8fa204c9b92772dc7d322bad15b5ce3c92 |
Hashes for cornflakes-3.1.2-cp39-cp39-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6600507237e292f7b5f97657d69a24845b48b974f9dc02a7b207063f6bef18aa |
|
MD5 | 60d7f58321d2ddae44ab3d3bea811344 |
|
BLAKE2b-256 | af11cd1dad36ae576f1a3fae0c72ccf7b297651bbbc0247dc3fc2101200f5119 |
Hashes for cornflakes-3.1.2-cp39-cp39-manylinux_2_35_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 39e9aed443d32a15a80fc22fa9bf53bb06ff8579f82657961ee2937c8e48aa11 |
|
MD5 | 5f5295c31dafbb3056f62b65a4b01d98 |
|
BLAKE2b-256 | 538e5a4fc20af75fe1b5aed3a1c5211d6e3dcac5633ff54b600bd23b28d31b14 |
Hashes for cornflakes-3.1.2-cp39-cp39-macosx_10_15_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9dcab7038078b96306d20ebed43cae2cede25b3bc683f7bb2ad4daef9e57c5c6 |
|
MD5 | 259aee2900a143177ec42dca8cd3e22b |
|
BLAKE2b-256 | f674ff6714741a9bc6271d0894aa99afc5984826283db64cee50ce3ae55a7fec |
Hashes for cornflakes-3.1.2-cp38-cp38-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 93d72122e776a4d0d3790dd9c0d6c4bc445aa29de6ae97beb600208132ebdbb5 |
|
MD5 | a23d289db2b9764893a519abbdfec139 |
|
BLAKE2b-256 | 6bbd3a0b9f243bf87aa08dba4fe6e02cff974cd1fe191f7e62eb44023fa259a5 |
Hashes for cornflakes-3.1.2-cp38-cp38-manylinux_2_35_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c589e073850386dc3df95fd4507da260184ce02d27d5568c36bf3618820d24db |
|
MD5 | ecea644f35200a2e7b4a946fc5227b7e |
|
BLAKE2b-256 | 0954a97a3926fb9eecee2761c06a7e98054f11753c05dadebc973d5cc7c9a36c |
Hashes for cornflakes-3.1.2-cp38-cp38-macosx_10_15_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 098eb13bb4f0f5e172d841df7dbcf272e0b0c725bcff8588a84be40fe9787dbe |
|
MD5 | ea7227c052d1105b837311dc51de852b |
|
BLAKE2b-256 | 77a07c91543c31dfce3c2731f209d106464fdb5623fb41997d166e8c4c6d534e |