{ "info": { "author": "Helgi \u00deorbj\u00f6rnsson", "author_email": "helgi@php.net", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Programming Language :: Python", "Programming Language :: Python :: 2.6", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.2", "Programming Language :: Python :: 3.3", "Topic :: Utilities" ], "description": "SimpleConfigParser\r\n==================\r\n[![Build Status](https://travis-ci.org/helgi/python-simpleconfigparser.png)](https://travis-ci.org/helgi/python-simpleconfigparser)\r\n\r\nBuilds on top of the builtin SafeConfigParser but adds various convenience functionalities.\r\n\r\n* Access to all the usual ConfigParser functionality\r\n* Access sections and items via convience objects and dicts instead of `get()`\r\n* Makes accessing items and section via dicts possible on Python 2.7+, ConfigParser has that from Python 3.2 onwards as a default\r\n* Ability to set values via the objects `config.section.item = 'demmmmm'` and dicts `config['section']['item']` all while `write()` still work as normal\r\n* Make a few functions work directly from the section object `config.section.items()`, `config.section.getboolean('item')`\r\n* Strips any quotes on the edgeds of items used in the INI file instead of returning it as part of the values\r\n* Improve the defaults handling on the object to be more sensible\r\n\r\n```python\r\ndefaults = {\r\n 'section': {\r\n 'item1': 'boo',\r\n 'item2': 'bar'\r\n }\r\n}\r\n\r\nconfig = simpleconfigparser(defaults=defaults)\r\n```\r\n\r\n\r\nExamples\r\n========\r\ncontents of read.ini:\r\n```ini\r\n[app]\r\ndebug = yes\r\n````\r\n\r\ntest.py:\r\n```python\r\nfrom simpleconfigparser import simpleconfigparser\r\n\r\nconfig = simpleconfigparser()\r\nconfig.read('read.ini')\r\n\r\nprint(config.app.debug)\r\nprint(config.app.getboolean('debug'))\r\nprint(config['app']['debug'])\r\nprint(config['app'].getboolean('debug'))\r\nconfig.app.debug = no\r\nwith open('new.ini', 'wb') as handle:\r\n config.write(handle)\r\n```\r\n\r\nLicense\r\n=======\r\nMIT - See LICENSE file", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://github.com/helgi/python-simpleconfigparser", "keywords": "ConfiParser,ini", "license": "MIT License", "maintainer": "", "maintainer_email": "", "name": "SimpleConfigParser2", "package_url": "https://pypi.org/project/SimpleConfigParser2/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/SimpleConfigParser2/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://github.com/helgi/python-simpleconfigparser" }, "release_url": "https://pypi.org/project/SimpleConfigParser2/0.1.0/", "requires_dist": null, "requires_python": null, "summary": "Simplifies and enchances functionalities in Python's ConfigParser", "version": "0.1.0" }, "last_serial": 603265, "releases": { "0.1.0": [] }, "urls": [] }