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

Inirama -- Simplest parser for INI files. Interpolation supported.

Project description

Inirama – Simplest parser for INI-style files.

Features:

  • One single module;
  • No requirements;
  • Tiny interface;
  • Supports variable interpolation;
Build Status Coverals Version Downloads Donate

Docs are available at https://inirama.readthedocs.org/. Pull requests with documentation enhancements and/or fixes are awesome and most welcome.

Requirements

  • python (2.6, 2.7, 3.2, 3.3)

Installation

Inirama could be installed using pip:

pip install inirama

Quickstart

from inirama import Namespace

ns = Namespace()
ns.read('config.ini')

print ns['section']['key']

ns['other']['new'] = 'value'
ns.write('new_config.ini')

Interpolation

from inirama import InterpolationNamespace

ns = InterpolationNamespace()
ns.parse("""
    [main]
    test = value
    foo = bar {test}
    more_deep = wow {foo}
""")
print ns['main']['more_deep']  # wow bar value

Bug tracker

If you have any suggestions, bug reports or annoyances please report them to the issue tracker at https://github.com/klen/inirama/issues

Contributing

Development of inirama happens at github: https://github.com/klen/inirama

Contributors

  • klen (Kirill Klenov)

License

Licensed under a BSD license.

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 Inirama, version 0.8.0
Filename, size File type Python version Upload date Hashes
Filename, size Inirama-0.8.0-py2.py3-none-any.whl (7.4 kB) File type Wheel Python version 2.7 Upload date Hashes View hashes
Filename, size Inirama-0.8.0.tar.gz (6.6 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page