{ "info": { "author": "Hal Blackburn", "author_email": "hal@caret.cam.ac.uk", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: Console", "Framework :: Django", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2.6", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Topic :: Internet :: WWW/HTTP", "Topic :: Software Development" ], "description": "Django-dj\n=========\n\nDjango-dj is a console command which removes the need to use Django's \n``manage.py`` script.\n\nOld way\n-------\n\n::\n\n $ django-project> python manage.py runserver/syncdb/etc\n\n::\n\n $ django-project/some/dir> python ../../manage.py runserver/syncdb/etc\n\nNew Way\n-------\n\n::\n\n $ django-project> dj runserver/syncdb/etc\n\n::\n\n $ django-project/some/dir> dj runserver/syncdb/etc\n\nInstead of carefully referencing ``manage.py`` from whichever directory you\nhappen to be in, ``dj`` works anywhere in or under your Django project \ndirectory. You can even completely remove your ``manage.py`` file if you wish.\n\n``dj`` identifies Django projects by looking for directories which are Python\npackages containing ``settings`` and ``urls`` submodules.\n\nInstalling\n----------\n\nWith ``pip``, run the command::\n\n sudo pip install django-dj\n\nOr with ``easy_install`` run::\n\n sudo easy_install django-dj\n\nAlternatively, you can manually install by copying the ``dj`` file to somewhere\non your ``$PATH``, perhaps ``~/bin/``.\n\nHow ``dj`` finds Django projects\n----------------------------\n\nAs mentioned above, ``dj`` identifys Django projects by looking for directories\nwhich are Python packages (e.g. contain an ``__init__.py[oc]`` file) containing\nthe following submodules:\n\n* ``settings``\n* ``urls``\n\nIf a package directory contains both submodules then ``dj`` takes it to be a\nDjango project and tries to run Django's management tool on it.\n\nPython modules/packages are identified by looking for ``.py``/``.pyc``/``.pyo``\nfiles of the correct name, or directories of the correct name containing a\n``__init__.py``/``.pyc``/``.pyo`` file. For performance and security reasons\nPython's own import functionality is not used (no Python modules are executed\nwhile searching for Django projects).\n\nSearch Strategy\n+++++++++++++++\n\nThe directories ``dj`` looks in are chosen as follows. The search starts in the\nworking directory this script is executed from and moves upwards to the parent\ndirectory, and then the parent's parent directory and so forth until either a\nDjango project is found, or the root of the filesystem is reached.\n\nIf a file named ``.djangoproject`` is encountered during the search, a complete\nsearch of the subtree at the directory holding the ``.djangoproject`` file is \ntriggered.\n\nInvoking ``dj`` from sibling directories of a Django project\n------------------------------------------------------------\n\nThe strategy of looking through the parent directories works well so long\nas long as ``dj`` is executed from a child directory of the Django project. \nConsider the following project structure::\n\n myproject/\n |-- staticfiles/\n |-- somefile.jpg\n |-- somefile.png\n |-- somefile.gif\n |-- django-project/\n |-- urls.py\n |-- settings.py\n |-- __init__.py\n\nIf you run ``dj`` from inside ``staticfiles``, it won't find ``django-project``\nbecause it will just check parents of ``staticfiles``, and ``django-project`` is\nnot a parent of ``staticfiles``. You can make ``dj`` find ``django-project`` by\ncreating an empty file called ``.djangoproject`` in in a common parent of \n``staticfiles`` and ``django-project``. In this case creating it in \n``myproject`` would work. This will tell dj to do a full search of all\ndirectories under ``myproject`` rather than just its parents.", "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/h4l/Django-dj", "keywords": null, "license": "BSD", "maintainer": null, "maintainer_email": null, "name": "Django-dj", "package_url": "https://pypi.org/project/Django-dj/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/Django-dj/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/h4l/Django-dj" }, "release_url": "https://pypi.org/project/Django-dj/0.3.0/", "requires_dist": null, "requires_python": null, "summary": "A short command which replaces calls to Django's manage.py scripts", "version": "0.3.0" }, "last_serial": 784141, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "3ecfc80f88eefe12eb6d71b2551fe767", "sha256": "25df8926f99f263a8495ab9304813a749481daee6d4c054c35e3034f8c33d8f5" }, "downloads": -1, "filename": "Django-dj-0.1.0.tar.gz", "has_sig": false, "md5_digest": "3ecfc80f88eefe12eb6d71b2551fe767", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3107, "upload_time": "2012-06-08T16:47:33", "url": "https://files.pythonhosted.org/packages/06/76/c81e3446ee6a774a99cf2fc7fc6b93565f6026aed7abcef97a3a3213be3b/Django-dj-0.1.0.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "3339433ff2f0a5961d739428b5749f6c", "sha256": "34da6a648ad475c59eced1b0a99d720b3b0c53672108a3f03798c13b0f09f630" }, "downloads": -1, "filename": "Django-dj-0.2.0.tar.gz", "has_sig": false, "md5_digest": "3339433ff2f0a5961d739428b5749f6c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4999, "upload_time": "2012-06-09T18:51:19", "url": "https://files.pythonhosted.org/packages/f3/fe/49e7708a9084e393fb3579d3f4b61ab4a88c12dd333de4206bdadbac7113/Django-dj-0.2.0.tar.gz" } ], "0.3.0": [ { "comment_text": "", "digests": { "md5": "beb8a970d24cb84a5725770a2cc7db37", "sha256": "e685ac6124567c01a69b4500300ae8113d0c566fa2b38d84b35fd8ab1a3e4c25" }, "downloads": -1, "filename": "Django-dj-0.3.0.tar.gz", "has_sig": false, "md5_digest": "beb8a970d24cb84a5725770a2cc7db37", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6724, "upload_time": "2013-03-19T00:24:34", "url": "https://files.pythonhosted.org/packages/0c/01/6670d20ea744e65a166885e8ab489476b22598227e59a0cba1157004d071/Django-dj-0.3.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "beb8a970d24cb84a5725770a2cc7db37", "sha256": "e685ac6124567c01a69b4500300ae8113d0c566fa2b38d84b35fd8ab1a3e4c25" }, "downloads": -1, "filename": "Django-dj-0.3.0.tar.gz", "has_sig": false, "md5_digest": "beb8a970d24cb84a5725770a2cc7db37", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6724, "upload_time": "2013-03-19T00:24:34", "url": "https://files.pythonhosted.org/packages/0c/01/6670d20ea744e65a166885e8ab489476b22598227e59a0cba1157004d071/Django-dj-0.3.0.tar.gz" } ] }