django-nine


Namedjango-nine JSON
Version 0.2.7 PyPI version JSON
download
home_pagehttps://github.com/barseghyanartur/django-nine/
SummaryVersion checking library.
upload_time2022-12-05 20:57:43
maintainer
docs_urlNone
authorArtur Barseghyan
requires_python
licenseGPL-2.0-only OR LGPL-2.1-or-later
keywords django compatibility
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI
coveralls test coverage
            ===========
django-nine
===========
`django-nine` - version checking library for Django.

.. image:: https://img.shields.io/pypi/v/django-nine.svg
   :target: https://pypi.python.org/pypi/django-nine
   :alt: PyPI Version

.. image:: https://img.shields.io/pypi/pyversions/django-nine.svg
    :target: https://pypi.python.org/pypi/django-nine/
    :alt: Supported Python versions

.. image:: https://github.com/barseghyanartur/django-nine/actions/workflows/test.yml/badge.svg
   :target: https://github.com/barseghyanartur/django-nine/actions/workflows/test.yml
   :alt: Build Status

.. image:: https://readthedocs.org/projects/django-nine/badge/?version=latest
    :target: http://django-nine.readthedocs.io/en/latest/?badge=latest
    :alt: Documentation Status

.. image:: https://img.shields.io/badge/license-GPL--2.0--only%20OR%20LGPL--2.1--or--later-blue.svg
   :target: https://github.com/barseghyanartur/django-nine/#License
   :alt: GPL-2.0-only OR LGPL-2.1-or-later

.. image:: https://coveralls.io/repos/github/barseghyanartur/django-nine/badge.svg?branch=master
    :target: https://coveralls.io/github/barseghyanartur/django-nine?branch=master
    :alt: Coverage

Prerequisites
=============
- Python 3.7, 3.8, 3.9 and 3.10.
- Django 1.5, 1.6, 1.7, 1.8, 1.9, 1.10, 1.11, 2.0, 2.1, 2.2, 3.0, 3.1, 3.2,
  4.0 and 4.1.

Documentation
=============
Documentation is available on `Read the Docs
<http://django-nine.readthedocs.io/>`_.

Installation
============
Install latest stable version from PyPI:

.. code-block:: sh

    pip install django-nine

Or latest stable version from GitHub:

.. code-block:: sh

    pip install https://github.com/barseghyanartur/django-nine/archive/stable.zip

Usage
=====
Get Django versions
-------------------
In code
~~~~~~~
For example, if Django version installed in your environment is 1.7.4, then
the following would be true.

.. code-block:: python

    from django_nine import versions

    versions.DJANGO_1_7  # True
    versions.DJANGO_LTE_1_7  # True
    versions.DJANGO_GTE_1_7  # True
    versions.DJANGO_GTE_1_8  # False
    versions.DJANGO_GTE_1_4  # True
    versions.DJANGO_LTE_1_6  # False

In templates
~~~~~~~~~~~~
With use of context processors
##############################
Add ``nine.context_processors.versions`` to your context processors.

.. code-block:: python

    TEMPLATES[0]['OPTIONS']['context_processors'] += \
        ['django_nine.context_processors.versions']

Or if you are using an old version of Django:

.. code-block:: python

    TEMPLATE_CONTEXT_PROCESSORS += ['django_nine.context_processors.versions']

Testing
=======
Simply type:

.. code-block:: sh

    ./runtests.py

Or use tox:

.. code-block:: sh

    tox

Or use tox to check specific env:

.. code-block:: sh

    tox -e py37

Or run Django tests:

.. code-block:: sh

    ./manage.py test nine --settings=settings.testing

License
=======
GPL-2.0-only OR LGPL-2.1-or-later

Support
=======
For any security issues contact me at the e-mail given in the `Author`_ section.
For overall issues, go to `GitHub <https://github.com/barseghyanartur/django-nine/issues>`_.

Author
======
Artur Barseghyan <artur.barseghyan@gmail.com>

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/barseghyanartur/django-nine/",
    "name": "django-nine",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "django,compatibility",
    "author": "Artur Barseghyan",
    "author_email": "artur.barseghyan@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/54/15/6e2a72c1c08f4a7e57c931632853aaf2659b9dc4a9906e887a2743b241e0/django-nine-0.2.7.tar.gz",
    "platform": null,
    "description": "===========\ndjango-nine\n===========\n`django-nine` - version checking library for Django.\n\n.. image:: https://img.shields.io/pypi/v/django-nine.svg\n   :target: https://pypi.python.org/pypi/django-nine\n   :alt: PyPI Version\n\n.. image:: https://img.shields.io/pypi/pyversions/django-nine.svg\n    :target: https://pypi.python.org/pypi/django-nine/\n    :alt: Supported Python versions\n\n.. image:: https://github.com/barseghyanartur/django-nine/actions/workflows/test.yml/badge.svg\n   :target: https://github.com/barseghyanartur/django-nine/actions/workflows/test.yml\n   :alt: Build Status\n\n.. image:: https://readthedocs.org/projects/django-nine/badge/?version=latest\n    :target: http://django-nine.readthedocs.io/en/latest/?badge=latest\n    :alt: Documentation Status\n\n.. image:: https://img.shields.io/badge/license-GPL--2.0--only%20OR%20LGPL--2.1--or--later-blue.svg\n   :target: https://github.com/barseghyanartur/django-nine/#License\n   :alt: GPL-2.0-only OR LGPL-2.1-or-later\n\n.. image:: https://coveralls.io/repos/github/barseghyanartur/django-nine/badge.svg?branch=master\n    :target: https://coveralls.io/github/barseghyanartur/django-nine?branch=master\n    :alt: Coverage\n\nPrerequisites\n=============\n- Python 3.7, 3.8, 3.9 and 3.10.\n- Django 1.5, 1.6, 1.7, 1.8, 1.9, 1.10, 1.11, 2.0, 2.1, 2.2, 3.0, 3.1, 3.2,\n  4.0 and 4.1.\n\nDocumentation\n=============\nDocumentation is available on `Read the Docs\n<http://django-nine.readthedocs.io/>`_.\n\nInstallation\n============\nInstall latest stable version from PyPI:\n\n.. code-block:: sh\n\n    pip install django-nine\n\nOr latest stable version from GitHub:\n\n.. code-block:: sh\n\n    pip install https://github.com/barseghyanartur/django-nine/archive/stable.zip\n\nUsage\n=====\nGet Django versions\n-------------------\nIn code\n~~~~~~~\nFor example, if Django version installed in your environment is 1.7.4, then\nthe following would be true.\n\n.. code-block:: python\n\n    from django_nine import versions\n\n    versions.DJANGO_1_7  # True\n    versions.DJANGO_LTE_1_7  # True\n    versions.DJANGO_GTE_1_7  # True\n    versions.DJANGO_GTE_1_8  # False\n    versions.DJANGO_GTE_1_4  # True\n    versions.DJANGO_LTE_1_6  # False\n\nIn templates\n~~~~~~~~~~~~\nWith use of context processors\n##############################\nAdd ``nine.context_processors.versions`` to your context processors.\n\n.. code-block:: python\n\n    TEMPLATES[0]['OPTIONS']['context_processors'] += \\\n        ['django_nine.context_processors.versions']\n\nOr if you are using an old version of Django:\n\n.. code-block:: python\n\n    TEMPLATE_CONTEXT_PROCESSORS += ['django_nine.context_processors.versions']\n\nTesting\n=======\nSimply type:\n\n.. code-block:: sh\n\n    ./runtests.py\n\nOr use tox:\n\n.. code-block:: sh\n\n    tox\n\nOr use tox to check specific env:\n\n.. code-block:: sh\n\n    tox -e py37\n\nOr run Django tests:\n\n.. code-block:: sh\n\n    ./manage.py test nine --settings=settings.testing\n\nLicense\n=======\nGPL-2.0-only OR LGPL-2.1-or-later\n\nSupport\n=======\nFor any security issues contact me at the e-mail given in the `Author`_ section.\nFor overall issues, go to `GitHub <https://github.com/barseghyanartur/django-nine/issues>`_.\n\nAuthor\n======\nArtur Barseghyan <artur.barseghyan@gmail.com>\n",
    "bugtrack_url": null,
    "license": "GPL-2.0-only OR LGPL-2.1-or-later",
    "summary": "Version checking library.",
    "version": "0.2.7",
    "split_keywords": [
        "django",
        "compatibility"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "md5": "5ef4f0f7b6d0252113c894ddfad6eb7d",
                "sha256": "4d93208ca5bb4a63bf65cf098a82ee469127b04ebde698d72fe12d258b73c291"
            },
            "downloads": -1,
            "filename": "django_nine-0.2.7-py2.py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "5ef4f0f7b6d0252113c894ddfad6eb7d",
            "packagetype": "bdist_wheel",
            "python_version": "py2.py3",
            "requires_python": null,
            "size": 25355,
            "upload_time": "2022-12-05T20:57:41",
            "upload_time_iso_8601": "2022-12-05T20:57:41.530697Z",
            "url": "https://files.pythonhosted.org/packages/c1/a8/8188786f7922cc47f394572eff37b4fd2202e0a75bcb9c15dd9234b0ccd8/django_nine-0.2.7-py2.py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "md5": "535ad6230307ab4746d445f541f837da",
                "sha256": "304e0f83cea5a35359375fc919d00f9917b655c1d388244cbfc7363f59489177"
            },
            "downloads": -1,
            "filename": "django-nine-0.2.7.tar.gz",
            "has_sig": false,
            "md5_digest": "535ad6230307ab4746d445f541f837da",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 20827,
            "upload_time": "2022-12-05T20:57:43",
            "upload_time_iso_8601": "2022-12-05T20:57:43.684942Z",
            "url": "https://files.pythonhosted.org/packages/54/15/6e2a72c1c08f4a7e57c931632853aaf2659b9dc4a9906e887a2743b241e0/django-nine-0.2.7.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2022-12-05 20:57:43",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "barseghyanartur",
    "github_project": "django-nine",
    "travis_ci": true,
    "coveralls": true,
    "github_actions": true,
    "tox": true,
    "lcname": "django-nine"
}
        
Elapsed time: 0.03026s