Skip to main content
Join the official 2020 Python Developers SurveyStart the survey!

INI style files parser with basic inheritance feature.

Project description

Confiskus is ini-file parse helper with simple inheritance feature.

Install

$ pip install confiskus

Usage

Inheritance is accomplished by extends option in default section.

Content of dev_conf.ini.

[default]
extends = base.ini

[webservice]
url = https://localhost:6543

Content of base.ini.

[webservice]
user = web_service_user
password = papluhaogrcalmikrpce
url = https://ws.otherserver.com

Now while reading dev_conf.ini confiskus will pick up also base.ini.

>>> import confiskus
>>> config = confiskus.Confiskus().read('dev_conf.ini')
>>> config.get('webservice', 'url')
'https://localhost:6543'
>>> config.get('webservice', 'user')
'web_service_user'

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for confiskus, version 1.0.6
Filename, size File type Python version Upload date Hashes
Filename, size confiskus-1.0.6.tar.gz (3.0 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page