Read settings from config files
Low maintenance activity. Last release 14 months ago. Weaker on commit activity and recent releases.
Consider insteadlib-layered-configPythie’s Index: 82280.9K downloads/moCompare →
pip install maisonMaison
Read configuration settings from configuration files.
📚 View Documentation | 🐛 Report a Bug | ✨ Request a Feature
Motivation
When developing a python package, e.g a command-line tool, it can be helpful
to allow the user to set their own configuration options to allow them to tailor
the tool to their needs. These options are typically set in files in the root of
a user's directory that uses the tool, for example in a pyproject.toml or an
{project_name}.ini file.
maison aims to provide a simple and flexible way to read and validate those
configuration options so that they may be used in the package.
Features
- Supports multiple config files and multiple config filetypes.
- Optional merging of multiple configs.
- Optional config validation with pydantic.
- Caching of config files for quick access.
- Fully tested and typed.
Installation
You can install maison via pip from PyPI:
pip install maison
Installation for Development
To set up maison for local development:
- Clone the repository:
git clone https://github.com/dbatten/maison.git cd maison