mirror of
https://github.com/pacnpal/django-anymail.git
synced 2025-12-20 11:51:05 -05:00
Maintain version info in a single place.
http://stackoverflow.com/a/2073599/647002
This commit is contained in:
@@ -4,8 +4,7 @@ from django.utils.text import capfirst
|
||||
|
||||
from djrill.exceptions import MandrillAPIError, NotSupportedByMandrillError
|
||||
|
||||
VERSION = (0, 3, 1)
|
||||
__version__ = '.'.join([str(x) for x in VERSION])
|
||||
from ._version import *
|
||||
|
||||
# This backend was developed against this API endpoint.
|
||||
# You can override in settings.py, if desired.
|
||||
|
||||
3
djrill/_version.py
Normal file
3
djrill/_version.py
Normal file
@@ -0,0 +1,3 @@
|
||||
VERSION = (0, 3, 1)
|
||||
__version__ = '.'.join([str(x) for x in VERSION])
|
||||
__minor_version__ = '.'.join([str(x) for x in VERSION[:2]]) # Sphinx's X.Y "version"
|
||||
@@ -16,7 +16,9 @@ import sys, os
|
||||
# If extensions (or modules to document with autodoc) are in another directory,
|
||||
# add these directories to sys.path here. If the directory is relative to the
|
||||
# documentation root, use os.path.abspath to make it absolute, like shown here.
|
||||
#sys.path.insert(0, os.path.abspath('.'))
|
||||
sys.path.insert(0, os.path.abspath('..'))
|
||||
|
||||
execfile('../djrill/_version.py')
|
||||
|
||||
# -- General configuration -----------------------------------------------------
|
||||
|
||||
@@ -48,9 +50,9 @@ copyright = u'2013, Djrill contributors (see AUTHORS.txt)'
|
||||
# built documents.
|
||||
#
|
||||
# The short X.Y version.
|
||||
version = '0.3'
|
||||
version = __minor_version__
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = '0.3.1'
|
||||
release = __version__
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
|
||||
3
setup.py
3
setup.py
@@ -1,4 +1,5 @@
|
||||
from setuptools import setup
|
||||
execfile('djrill/_version.py')
|
||||
|
||||
with open('LICENSE') as file:
|
||||
license_text = file.read()
|
||||
@@ -7,7 +8,7 @@ with open('README.rst') as file:
|
||||
|
||||
setup(
|
||||
name="djrill",
|
||||
version="0.3.1",
|
||||
version=__version__,
|
||||
description='Django email backend for Mandrill.',
|
||||
keywords="django, mailchimp, mandrill, email, email backend",
|
||||
author="Kenneth Love <kenneth@brack3t.com>, Chris Jones <chris@brack3t.com>",
|
||||
|
||||
Reference in New Issue
Block a user