Skip to content

Commit 593018b

Browse files
committed
enable myst substitutions
1 parent 5b168a2 commit 593018b

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

docs/source/conf.py

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,6 @@
2222

2323
target_libzmq = '%i.%i.%i' % bundled_version
2424

25-
rst_epilog = f"""
26-
.. |target_libzmq| replace:: {target_libzmq}
27-
"""
28-
2925
# -- General configuration -----------------------------------------------------
3026

3127
# Add any Sphinx extension module names here, as strings. They can be extensions
@@ -43,7 +39,9 @@
4339
"colon_fence",
4440
"linkify",
4541
"smartquotes",
42+
"substitution",
4643
]
44+
4745
# Add any paths that contain templates here, relative to this directory.
4846
templates_path = ['_templates']
4947

@@ -73,10 +71,16 @@
7371
import zmq
7472

7573
# The short X.Y version.
76-
version = zmq.__version__.split('-')[0]
74+
version = '.'.join(zmq.__version__.split('.')[:2])
7775
# The full version, including alpha/beta/rc tags.
7876
release = zmq.__version__
7977

78+
myst_substitutions = {
79+
"version": version,
80+
"release": release,
81+
"target_libzmq": target_libzmq,
82+
}
83+
8084
# The language for content autogenerated by Sphinx. Refer to documentation
8185
# for a list of supported languages.
8286
# language = None

0 commit comments

Comments
 (0)