Added __version_info__ and single source version

pull/205/head
Ashley Whetter 4 years ago
parent 2e875f81c3
commit 2f87d5ef82

@ -3,8 +3,24 @@ Changelog
Versions follow `Semantic Versioning <https://semver.org/>`_ (``<major>.<minor>.<patch>``).
v1.3.1 (2020-04-05)
-------------------
Features
^^^^^^^^
* `#197 <https://github.com/readthedocs/sphinx-autoapi/issues/197>`: Added
``autoapi.__version__`` and ``autoapi.__version_info__`` attributes
for accessing version information.
Bug Fixes
^^^^^^^^^
Trivial/Internal Changes
^^^^^^^^^^^^^^^^^^^^^^^^
v1.3.0 (2020-04-05)
------------
-------------------
Breaking Changes
^^^^^^^^^^^^^^^^
@ -13,7 +29,8 @@ Breaking Changes
Features
^^^^^^^^
* `#151 <https://github.com/readthedocs/sphinx-autoapi/issues/151>`: (Python) Added the ``autoapi_python_use_implicit_namespaces`` option to allow
* `#151 <https://github.com/readthedocs/sphinx-autoapi/issues/151>`: (Python)
Added the ``autoapi_python_use_implicit_namespaces`` option to allow
AutoAPI to search for implicit namespace packages.
* Added support for Sphinx 2.2 and 2.3.
* Added support for Python 3.8.
@ -47,7 +64,7 @@ Trivial/Internal Changes
v1.2.1 (2019-10-09)
------------------
-------------------
Bug Fixes
^^^^^^^^^
@ -57,7 +74,7 @@ Bug Fixes
v1.2.0 (2019-10-05)
------------------
-------------------
Features
^^^^^^^^
@ -107,18 +124,21 @@ v1.0.0 (2019-04-24)
Features
^^^^^^^^
* `#100 <https://github.com/readthedocs/sphinx-autoapi/issues/100>`: (Python) Added support for documenting C extensions via ``.pyi`` stub files.
* `#100 <https://github.com/readthedocs/sphinx-autoapi/issues/100>`: (Python)
Added support for documenting C extensions via ``.pyi`` stub files.
* Added support for Sphinx 2.0.
* Toned down the API reference index page.
* (Go) Patterns configured in ``autoapi_ignore`` are passed to godocjson.
* New and improved documentation.
* No longer need to set ``autoapi_add_toctree_entry`` to False when ``autoapi_generate_api_docs`` is False.
* `#139 <https://github.com/readthedocs/sphinx-autoapi/issues/139>` Added support for basic type annotations in documentation generation and autodoc-style directives.
* `#139 <https://github.com/readthedocs/sphinx-autoapi/issues/139>`
Added support for basic type annotations in documentation generation and autodoc-style directives.
Bug Fixes
^^^^^^^^^
* `#159 <https://github.com/readthedocs/sphinx-autoapi/issues/159>`: (Python) Fixed ``UnicodeDecodeError`` on Python 2 when a documenting an attribute that contains binary data.
* `#159 <https://github.com/readthedocs/sphinx-autoapi/issues/159>`: (Python)
Fixed ``UnicodeDecodeError`` on Python 2 when a documenting an attribute that contains binary data.
* (Python) Fixed private submodules displaying when ``private-members`` is turned off.
* Templates no longer produce excessive whitespace.
* (Python) Fixed an error when giving an invalid object to an autodoc-style directive.

@ -2,6 +2,5 @@
Sphinx AutoAPI
"""
__version__ = "1.3.0"
from .extension import setup
from ._version import __version__, __version_info__

@ -0,0 +1,2 @@
__version_info__ = (1, 3, 0)
__version__ = ".".join(str(x) for x in __version_info__)

@ -51,10 +51,11 @@ author = u'Read the Docs, Inc'
# |version| and |release|, also used in various other places throughout the
# built documents.
#
import autoapi
# The short X.Y version.
version = '1.3'
version = ".".join(str(x) for x in autoapi.__version_info__[:2])
# The full version, including alpha/beta/rc tags.
release = '1.3.0'
release = autoapi.__version__
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.

@ -2,10 +2,13 @@ import io
from setuptools import setup, find_packages
version = {}
with open("autoapi/_version.py") as fp:
exec(fp.read(), version)
setup(
name="sphinx-autoapi",
version="1.3.0",
version=version["__version__"],
author="Eric Holscher",
author_email="eric@ericholscher.com",
url="http://github.com/readthedocs/sphinx-autoapi",

Loading…
Cancel
Save