{ "info": { "author": "", "author_email": "", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Programming Language :: Python" ], "description": "voodooconfig\n============\n\n.. image:: https://travis-ci.org/esc/voodooconfig.svg?branch=master\n :target: https://travis-ci.org/esc/voodooconfig\n\nAncilliary library to process and hold a set of options when programming\ncommand-line interfaces.\n\nExample\n-------\n\nsee: `example.py `_\n\nInstallation\n------------\n\nInstall via PyPi::\n\n $ pip install voodooconfig\n\nWhat Problem does this Solve?\n-----------------------------\n\nImagine you are writing a command-line utility. This has a set of options with\nsome sane defaults. Furthermore there are one or more config-files and\nadditionally some command-line parameters. This class solve the problem of\naccumulating all of these. Importantly, this can be done such that values on\nthe command-line override those from the config-file(s) which again override\nthe defaults.\n\nAdditionally, the `VoodooConfig` class has some voodoo to allow both attribute\nand dictionary based access to the options stored within. So for example the\nfollowing are equivalent::\n\n >>> config['api_key']\n 'THEKEY'\n >>> config.api_key\n 'THEKEY'\n\nThis allows you to fill the class in a reflection based style, but at the same\ntime access the options pythonically::\n\n\n >>> loaded_config = {'api_key': 'NEW_KEY'}\n >>> for k,v in loaded_config:\n >>> config[k] = v\n\nThe last feature is that, when loading a config any hyphens are converted to\nunderscores. This is required, since Python attributes may not contain hyphens.\n\nMindset\n-------\n\nIt is a super-simple utility with lots of flexibility. I decided to publish it\nas separate package since I have been solving this exact same problem again and\nagain over the years and didn't want to keep re-inventing the wheel every time.\nThe interface is also super simple so that it can be combined with any of the\nmyriad of command-line interface tools that exist in Python. At the core,\noptions are just a mapping/dictionary so you can use those to insert values\nand/or export the options in a format suitable for processing by subsequent\ntools.\n\nLimitations\n-----------\n\n* Currently it kinda uses YAML as config-file syntax but that can be adapted.\n* There is no type-checking or parameter validation.\n* There is no way to declare required/optional options and any complex\n relationship between options, e.g. mutually exclusivity, can not be declared.\n\n\nLicense\n-------\n\nCopyright 2016 Valentin Haenel \n\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\nthis file except in compliance with the License. You may obtain a copy of the\nLicense at\n\nhttp://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software distributed\nunder the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR\nCONDITIONS OF ANY KIND, either express or implied. See the License for the\nspecific language governing permissions and limitations under the License.\n", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "voodooconfig", "package_url": "https://pypi.org/project/voodooconfig/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/voodooconfig/", "project_urls": null, "release_url": "https://pypi.org/project/voodooconfig/33.15/", "requires_dist": null, "requires_python": "", "summary": "", "version": "33.15" }, "last_serial": 2318599, "releases": { "1.0": [], "13.3": [ { "comment_text": "", "digests": { "md5": "10d010d9f1ef34b164829c43cb84165e", "sha256": "03c2b798e57981dde720c5af12b10b4d360267a0885e85be256a527e8b29972e" }, "downloads": -1, "filename": "voodooconfig-13.3.tar.gz", "has_sig": false, "md5_digest": "10d010d9f1ef34b164829c43cb84165e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3158, "upload_time": "2016-07-20T12:45:37", "url": "https://files.pythonhosted.org/packages/36/ac/b342979c62d2b56ef0cb810cbce7b75003f791bee3d7f08943d3527f1663/voodooconfig-13.3.tar.gz" } ], "14.4": [ { "comment_text": "", "digests": { "md5": "e9f861c6ed3a5fe68401eb949c70479e", "sha256": "6514f9c95daef7b3c64a9822d005a37fc8d45f6a0eb65a563f9feb81a1c13225" }, "downloads": -1, "filename": "voodooconfig-14.4.tar.gz", "has_sig": false, "md5_digest": "e9f861c6ed3a5fe68401eb949c70479e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3176, "upload_time": "2016-07-20T12:51:59", "url": "https://files.pythonhosted.org/packages/ef/46/b51543f71c912930d2a0e48eb359e7e265c4534bc5c738fc63f8e081afaa/voodooconfig-14.4.tar.gz" } ], "15.5": [ { "comment_text": "", "digests": { "md5": "0ebbb90878248bd759f13576bf3c5aa4", "sha256": "4b2c9ae060ee41fc010545fc82bf2059b9a5392b098bac13b47f82c2b92461a4" }, "downloads": -1, "filename": "voodooconfig-15.5.tar.gz", "has_sig": false, "md5_digest": "0ebbb90878248bd759f13576bf3c5aa4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3212, "upload_time": "2016-07-20T13:20:53", "url": "https://files.pythonhosted.org/packages/24/19/4d3630be86ff6f30daee931370aaa157e63adf24ccd376b1f7a9343c1719/voodooconfig-15.5.tar.gz" } ], "17.6": [ { "comment_text": "", "digests": { "md5": "551acfe8a11d421ec192bad1b602bfaf", "sha256": "b2fa1bd026db661b594ef23cb2d74fb25aa47012f8fde1d344403cb9801e0cdd" }, "downloads": -1, "filename": "voodooconfig-17.6.tar.gz", "has_sig": false, "md5_digest": "551acfe8a11d421ec192bad1b602bfaf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3169, "upload_time": "2016-07-20T13:48:26", "url": "https://files.pythonhosted.org/packages/9d/b9/a6d2d1fa9aed2532324494ef68d705fca0f722a0313c17d427434af0c2e3/voodooconfig-17.6.tar.gz" } ], "19.7": [ { "comment_text": "", "digests": { "md5": "30aa941ffa16c1f53dca1f70b318f72b", "sha256": "b5b3310510028de6fa0fe580d7ca8e594bd61680649b5d04db4bb130e0433b8f" }, "downloads": -1, "filename": "voodooconfig-19.7.tar.gz", "has_sig": false, "md5_digest": "30aa941ffa16c1f53dca1f70b318f72b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3197, "upload_time": "2016-07-20T13:52:13", "url": "https://files.pythonhosted.org/packages/c0/f3/d318d1a8cbdef12b6ca3d8de273108f0ef1f0d5e0ffed688c307e1d8f186/voodooconfig-19.7.tar.gz" } ], "21.8": [ { "comment_text": "", "digests": { "md5": "1807c0222ce887ed50b79248ef3b05d8", "sha256": "3fa80f12bbfce8bfbf806ede0e51261c3353817b0528a8fd10f545464c18b507" }, "downloads": -1, "filename": "voodooconfig-21.8.tar.gz", "has_sig": false, "md5_digest": "1807c0222ce887ed50b79248ef3b05d8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3197, "upload_time": "2016-07-20T15:20:37", "url": "https://files.pythonhosted.org/packages/55/2c/e69b610bdf0234abf9b310607034c6585f29e67898e17cf42b479bb2db9b/voodooconfig-21.8.tar.gz" } ], "23.9": [ { "comment_text": "", "digests": { "md5": "70df0c1572eb4ae61335cf8263283f94", "sha256": "4e6547d927c079253d6d4077cf7823c750f467e9349d6ba08d5af09f35c9916a" }, "downloads": -1, "filename": "voodooconfig-23.9.tar.gz", "has_sig": false, "md5_digest": "70df0c1572eb4ae61335cf8263283f94", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3193, "upload_time": "2016-07-21T07:22:25", "url": "https://files.pythonhosted.org/packages/6e/cb/3c8b10ac25ec8d0880d9f78fe78e5d59eb0da27c8c4727e303a0b69b24ab/voodooconfig-23.9.tar.gz" } ], "24.10": [ { "comment_text": "", "digests": { "md5": "1dd97e73805bf8c8ac3d2ccf67a554f2", "sha256": "1cc50a2143aa79c421a68378ea3079f58a7a0801fe591307d32359d837fc32b0" }, "downloads": -1, "filename": "voodooconfig-24.10.tar.gz", "has_sig": false, "md5_digest": "1dd97e73805bf8c8ac3d2ccf67a554f2", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3222, "upload_time": "2016-07-22T09:52:33", "url": "https://files.pythonhosted.org/packages/a1/25/fa382cc2fa1ddd131fff3d5f9b02799c5e5dfce560502a3027a473ad8147/voodooconfig-24.10.tar.gz" } ], "30.12": [ { "comment_text": "", "digests": { "md5": "5fadae897684da7e81002e95846cafe7", "sha256": "dcf4001be06dd23ed0bd837c882e28325ed4d7517e4c0abeae4640c1f8bce639" }, "downloads": -1, "filename": "voodooconfig-30.12.tar.gz", "has_sig": false, "md5_digest": "5fadae897684da7e81002e95846cafe7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3279, "upload_time": "2016-08-31T19:23:59", "url": "https://files.pythonhosted.org/packages/bf/77/0736ee40a3e3cf830913f0e6b56d5ee94ed2b227e7d1f7427beb2f8181e6/voodooconfig-30.12.tar.gz" } ], "31.13": [ { "comment_text": "", "digests": { "md5": "9a1caeae55e3add5655015fed88f7c4f", "sha256": "e9cf665bdbdd0c63e268218aadb13b95018507d2828ab1b812b7c69441d2d9ef" }, "downloads": -1, "filename": "voodooconfig-31.13.tar.gz", "has_sig": false, "md5_digest": "9a1caeae55e3add5655015fed88f7c4f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3275, "upload_time": "2016-08-31T19:25:53", "url": "https://files.pythonhosted.org/packages/e0/41/77b1a4a636d663decfa2bb2648e8215c96f1f76dbff0741204574232cf43/voodooconfig-31.13.tar.gz" } ], "32.14": [ { "comment_text": "", "digests": { "md5": "4b8fc6d6eda96185174512d1f9d28930", "sha256": "f0a57bd59baa680373b80d1f5ae68c7b840fd3cead6aaff5e8eb5c3765dffbe2" }, "downloads": -1, "filename": "voodooconfig-32.14.tar.gz", "has_sig": false, "md5_digest": "4b8fc6d6eda96185174512d1f9d28930", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3273, "upload_time": "2016-08-31T19:41:49", "url": "https://files.pythonhosted.org/packages/2a/76/9abd28b3376b8ef99abc59416b7ea156154862cf4ef642e0caed60a93b96/voodooconfig-32.14.tar.gz" } ], "33.15": [ { "comment_text": "", "digests": { "md5": "e4b5438f95e6b913cb04a1df5b611616", "sha256": "3552e6d9fbb3e5c7319ef664ad0d00232ce2b23ef145e5314de74ac7d84724c8" }, "downloads": -1, "filename": "voodooconfig-33.15.tar.gz", "has_sig": false, "md5_digest": "e4b5438f95e6b913cb04a1df5b611616", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3304, "upload_time": "2016-09-01T14:18:52", "url": "https://files.pythonhosted.org/packages/f8/97/5d9767ecd07c4015fa8c0a70c293f27b6075d3db415b744887ae2dc5d043/voodooconfig-33.15.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "e4b5438f95e6b913cb04a1df5b611616", "sha256": "3552e6d9fbb3e5c7319ef664ad0d00232ce2b23ef145e5314de74ac7d84724c8" }, "downloads": -1, "filename": "voodooconfig-33.15.tar.gz", "has_sig": false, "md5_digest": "e4b5438f95e6b913cb04a1df5b611616", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3304, "upload_time": "2016-09-01T14:18:52", "url": "https://files.pythonhosted.org/packages/f8/97/5d9767ecd07c4015fa8c0a70c293f27b6075d3db415b744887ae2dc5d043/voodooconfig-33.15.tar.gz" } ] }