File tree 3 files changed +34
-0
lines changed
3 files changed +34
-0
lines changed Original file line number Diff line number Diff line change
1
+ from functools import partial
2
+ from pathlib import Path
3
+
4
+ from setuptools_scm import get_version
5
+
6
+
1
7
extensions = ['sphinx.ext.autodoc' , 'jaraco.packaging.sphinx' , 'rst.linker' ]
2
8
3
9
master_doc = "index"
99
105
100
106
# Add support for inline tabs
101
107
extensions += ['sphinx_inline_tabs' ]
108
+
109
+ # Add support for the unreleased "next-version" change notes
110
+ extensions += ['sphinxcontrib.towncrier' ]
111
+
112
+
113
+ # -- Options for towncrier_draft extension --------------------------------------------
114
+
115
+ PROJECT_ROOT_DIR = Path (__file__ ).parents [1 ].resolve ()
116
+ get_scm_version = partial (get_version , root = PROJECT_ROOT_DIR )
117
+
118
+ # The short X.Y version
119
+ version = '.' .join (
120
+ get_scm_version (
121
+ local_scheme = 'no-local-version' ,
122
+ ).split ('.' )[:3 ],
123
+ )
124
+
125
+ # The full version, including alpha/beta/rc tags
126
+ release = get_scm_version ()
127
+
128
+ towncrier_draft_autoversion_mode = "draft" # or: 'sphinx-release', 'sphinx-version'
129
+ towncrier_draft_include_empty = True
130
+ towncrier_draft_working_directory = PROJECT_ROOT_DIR
131
+ # Not yet supported: towncrier_draft_config_path = 'pyproject.toml' # relative to cwd
Original file line number Diff line number Diff line change 5
5
History
6
6
*******
7
7
8
+ .. towncrier-draft-entries :: |release|, unreleased as on |today|
9
+
8
10
.. include :: ../CHANGES (links).rst
9
11
10
12
Credits
Original file line number Diff line number Diff line change 74
74
75
75
# local
76
76
pygments-github-lexers ==0.0.5
77
+ setuptools-scm
77
78
sphinx-inline-tabs
79
+ sphinxcontrib-towncrier
78
80
79
81
ssl =
80
82
wincertstore ==0.2; sys_platform=='win32'
You can’t perform that action at this time.
0 commit comments