{ "info": { "author": "Evandro Myller", "author_email": "emyller@7ws.co", "bugtrack_url": null, "classifiers": [ "Framework :: Django", "License :: OSI Approved :: MIT License", "Programming Language :: Python", "Programming Language :: Python :: 2.6", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.1", "Programming Language :: Python :: 3.2", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Topic :: Software Development" ], "description": "# django-setmagic\n\nMagically editable settings for winged pony lovers.\n\n\n## Why?\n\nBecause sometimes it's cool to set global configuration values through a nice\ninterface on the Django admin. And that's what SetMagic make possible. Enjoy!\n\n\n## Install and set up\n\nInstall it into your project's virtual environment:\n\n\t$ pip install django-setmagic\n\nMake sure you already have the [Django admin][1] set up! Then append to your\nDjango project's `INSTALLED_APPS` setting.\n\n\tINSTALLED_APPS = [\n\t\t...\n\t\t'django.contrib.admin',\n\t\t'setmagic',\n\t\t...\n\t]\n\nAlso enable the SetMagic template context processor, if you want to use it on\nyour templates, by adding it to the `TEMPLATE_CONTEXT_PROCESSORS` list:\n\n\tTEMPLATE_CONTEXT_PROCESSORS = [\n\t\t...\n\t\t'setmagic.context_processors.load_setmagic',\n\t]\n\nCreate the necessary tables, like usual:\n\n\t$ python manage.py syncdb\n\n...and that's pretty much it. :)\n\n\n## Usage\n\nSetMagic will look into your project's settings for the name `SETMAGIC_SCHEMA`.\nIt should be defined as a pure Python list of groups like the example below:\n\n\tSETMAGIC_SCHEMA = [\n\t ('Facebook App Credentials', [\n\t dict(\n\t name='FACEBOOK_APP_ID',\n\t label=u'Facebook app ID',\n\t help_text=u'Unique app identification code provided by Facebook.'),\n\t dict(\n\t name='FACEBOOK_APP_SECRET',\n\t label=u'Facebook API secret',\n\t help_text=u'Unique and secret API code provided by Facebook.'),\n\t ]),\n\t ('Tracking', [\n\t dict(\n\t name='GOOGLE_ANALYTICS_CODE',\n\t label=u'Google Analytics code',\n\t help_text=u'Domain to identify this site through the GA API.'),\n\t ]),\n\t]\n\nFrom now on, you should be able to set values for your configurations through\nthe Django admin. And you will, of course, be able to set and retrieve these\nvalues on your code.\n\n\tfrom setmagic import settings\n\n\t# Instantly save onto the database!\n\tsettings.FACEBOOK_APP_ID = '000000000000000'\n\n\t# Retrieve the setting value from the database\n\tprint(settings.FACEBOOK_APP_ID)\n\n\t# Deletes it from the database\n\tdel settings.FACEBOOK_APP_ID\n\nIf you added the template context processor like described above, you can also\nuse SetMagic values on your templates.\n\n\t

My Facebook app ID is {{ setmagic.FACEBOOK_APP_ID }}

\n\nSee? No mistery. :)\n\n\n## Platform support\n\n\t* Python 2.6+\n\t* Python 3.x\n\t* Django 1.5+\n\n\n## Contribute\n\nYou can play with the code at SetMagic's reposity on [GitHub][2] or [donate][3]\nme a few bucks from heart so I can write open source code without worrying too\nmuch about bills.\n\n\n[1]: https://docs.djangoproject.com/en/dev/ref/contrib/admin/\n[2]: http://github.com/7ws/django-setmagic\n[3]: https://gratipay.com/emyller/\n", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/7ws/django-setmagic", "keywords": "django,settings", "license": "UNKNOWN", "maintainer": null, "maintainer_email": null, "name": "django-setmagic", "package_url": "https://pypi.org/project/django-setmagic/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/django-setmagic/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/7ws/django-setmagic" }, "release_url": "https://pypi.org/project/django-setmagic/0.3/", "requires_dist": null, "requires_python": null, "summary": "Magically editable settings for winged pony lovers", "version": "0.3" }, "last_serial": 1228311, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "7a0129e44e3c4e2099b0267d2d9ecd1e", "sha256": "cd32e8bfe93f92b7e0601e0c5b8d31d1c7033b51a7df82fbee9ecc65df999825" }, "downloads": -1, "filename": "django-setmagic-0.1.tar.gz", "has_sig": false, "md5_digest": "7a0129e44e3c4e2099b0267d2d9ecd1e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3520, "upload_time": "2014-08-18T11:04:50", "url": "https://files.pythonhosted.org/packages/ca/53/afb3eed778e7029ae1d0c56e1db92d004f6ae55a6cf7c6a150928dc55b72/django-setmagic-0.1.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "ac116c5359947626ead84113e2150233", "sha256": "e8e254eaccc93765d96c9b6327d1b7beb0fc91d2468eb1ca9751f56570b429c9" }, "downloads": -1, "filename": "django-setmagic-0.1.1.tar.gz", "has_sig": false, "md5_digest": "ac116c5359947626ead84113e2150233", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3570, "upload_time": "2014-08-18T12:01:34", "url": "https://files.pythonhosted.org/packages/87/ef/efb1573fb51738d74efb9d63daa1aaf715c8431a629c7c83a182cb641dd5/django-setmagic-0.1.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "a6fabd9385a296a1b1bfede4880d8334", "sha256": "10ebb9cb171da8b119a951fb9d0d69a94d415a51f853094eafbe7d935b9a1d3a" }, "downloads": -1, "filename": "django-setmagic-0.1.2.tar.gz", "has_sig": false, "md5_digest": "a6fabd9385a296a1b1bfede4880d8334", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3591, "upload_time": "2014-08-18T12:07:38", "url": "https://files.pythonhosted.org/packages/b1/2c/2e692f953e3c3d6ffe207c9ae87be3d03236cc0632003ff87a1f5cb7200d/django-setmagic-0.1.2.tar.gz" } ], "0.2": [ { "comment_text": "", "digests": { "md5": "b898f454b99710a941f91d90c794e9e6", "sha256": "3416fa67fdee1024d4138b7e77a94afe6ad1c10457f1bb24e28e68f8b93cc1d0" }, "downloads": -1, "filename": "django-setmagic-0.2.tar.gz", "has_sig": false, "md5_digest": "b898f454b99710a941f91d90c794e9e6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6291, "upload_time": "2014-09-12T14:20:53", "url": "https://files.pythonhosted.org/packages/2b/0b/fa646ea600fa926ab5f80c4b05fbb0fdfca9810d4d3f6989cdabbd9fa3ef/django-setmagic-0.2.tar.gz" } ], "0.2.2": [ { "comment_text": "", "digests": { "md5": "2e934dfef1eab4d7b209b25a122ad9a7", "sha256": "b0a248fe9f9b3d40361682135673dcf2e760a7698093b290480e2cfe9dd83235" }, "downloads": -1, "filename": "django-setmagic-0.2.2.tar.gz", "has_sig": false, "md5_digest": "2e934dfef1eab4d7b209b25a122ad9a7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7536, "upload_time": "2014-09-12T18:36:05", "url": "https://files.pythonhosted.org/packages/65/b4/b692c1dfe736201b1201ed8414d9ef0d8812e4c6edaf88e73d72c7f51b8f/django-setmagic-0.2.2.tar.gz" } ], "0.3": [ { "comment_text": "", "digests": { "md5": "b9775055bf7a705ccac2120409d7fb3c", "sha256": "2fb4eba9b22c287e1082f648954e1a35600b45abf3f2d33d24ed42ed4d7d0e5a" }, "downloads": -1, "filename": "django-setmagic-0.3.tar.gz", "has_sig": false, "md5_digest": "b9775055bf7a705ccac2120409d7fb3c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7691, "upload_time": "2014-09-17T18:50:40", "url": "https://files.pythonhosted.org/packages/b0/57/17d64498ff2ceae6ec02833d45d4e2cf61cefdee1ccab5bfddb6649f7e59/django-setmagic-0.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "b9775055bf7a705ccac2120409d7fb3c", "sha256": "2fb4eba9b22c287e1082f648954e1a35600b45abf3f2d33d24ed42ed4d7d0e5a" }, "downloads": -1, "filename": "django-setmagic-0.3.tar.gz", "has_sig": false, "md5_digest": "b9775055bf7a705ccac2120409d7fb3c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7691, "upload_time": "2014-09-17T18:50:40", "url": "https://files.pythonhosted.org/packages/b0/57/17d64498ff2ceae6ec02833d45d4e2cf61cefdee1ccab5bfddb6649f7e59/django-setmagic-0.3.tar.gz" } ] }