|
16 | 16 | import sys
|
17 | 17 | import os
|
18 | 18 |
|
| 19 | +import django_babel |
| 20 | + |
| 21 | + |
| 22 | +def _short_version(release): |
| 23 | + parts = release.split('.') |
| 24 | + return '.'.join(parts[:2]) |
| 25 | + |
| 26 | + |
19 | 27 | # If extensions (or modules to document with autodoc) are in another directory,
|
20 | 28 | # add these directories to sys.path here. If the directory is relative to the
|
21 | 29 | # documentation root, use os.path.abspath to make it absolute, like shown here.
|
|
30 | 38 | # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
31 | 39 | # ones.
|
32 | 40 | extensions = [
|
| 41 | + 'sphinx.ext.autodoc', |
| 42 | + 'sphinx.ext.autosummary', |
33 | 43 | 'sphinx.ext.intersphinx',
|
| 44 | + 'sphinx.ext.todo', |
| 45 | + 'sphinx.ext.viewcode', |
34 | 46 | ]
|
35 | 47 |
|
36 | 48 | # Add any paths that contain templates here, relative to this directory.
|
|
52 | 64 | # The version info for the project you're documenting, acts as replacement for
|
53 | 65 | # |version| and |release|, also used in various other places throughout the
|
54 | 66 | # built documents.
|
55 |
| -# |
56 |
| -# The short X.Y version. |
57 |
| -version = '0.3.4' |
| 67 | + |
58 | 68 | # The full version, including alpha/beta/rc tags.
|
59 |
| -release = '0.3.4' |
| 69 | +release = django_babel.__version__ |
| 70 | +# The short X.Y version. |
| 71 | +version = _short_version(release) |
60 | 72 |
|
61 | 73 | # The language for content autogenerated by Sphinx. Refer to documentation
|
62 | 74 | # for a list of supported languages.
|
|
261 | 273 |
|
262 | 274 |
|
263 | 275 | # Example configuration for intersphinx: refer to the Python standard library.
|
264 |
| -intersphinx_mapping = {'http://docs.python.org/': None} |
| 276 | +intersphinx_mapping = {'https://docs.python.org/': None} |
0 commit comments