summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNed Batchelder <ned@nedbatchelder.com>2019-08-11 18:05:04 -0400
committerNed Batchelder <ned@nedbatchelder.com>2019-08-11 18:05:04 -0400
commita005ce15e11ad66e384b5eed095812db04bc9420 (patch)
tree36ad2a8ce5c470b0b97b6f2ed012ffcbe3fa7447
parent08a54d5d17a878241b6f7ac1e08f44aa55c782aa (diff)
downloadpython-coveragepy-git-a005ce15e11ad66e384b5eed095812db04bc9420.tar.gz
Fix autosphinx links in uploaded release notes
The :meth:`.CoverageData.foobar` syntax isn't understood by pandoc when converting to markdown. A Sphinx rst builder converts them into more basic Sphinx links first.
-rw-r--r--Makefile13
-rw-r--r--doc/conf.py1
-rw-r--r--doc/requirements.pip1
3 files changed, 9 insertions, 6 deletions
diff --git a/Makefile b/Makefile
index 6810fdeb..580f1f23 100644
--- a/Makefile
+++ b/Makefile
@@ -114,8 +114,8 @@ uninstall:
# Documentation
-SPHINXBUILD = .tox/doc/bin/sphinx-build
-SPHINXOPTS = -a -E doc
+SPHINXOPTS = -aE
+SPHINXBUILD = .tox/doc/bin/sphinx-build $(SPHINXOPTS)
WEBHOME = ~/web/stellated/
WEBSAMPLE = $(WEBHOME)/files/sample_coverage_html
WEBSAMPLEBETA = $(WEBHOME)/files/sample_coverage_html_beta
@@ -124,12 +124,12 @@ docreqs:
tox -q -e doc --notest
dochtml: docreqs
- $(SPHINXBUILD) -b html $(SPHINXOPTS) doc/_build/html
+ $(SPHINXBUILD) -b html doc doc/_build/html
@echo
@echo "Build finished. The HTML pages are in doc/_build/html."
docspell: docreqs
- $(SPHINXBUILD) -b spelling $(SPHINXOPTS) doc/_spell
+ $(SPHINXBUILD) -b spelling doc doc/_spell
publish:
rm -f $(WEBSAMPLE)/*.*
@@ -141,5 +141,6 @@ publishbeta:
mkdir -p $(WEBSAMPLEBETA)
cp doc/sample_html_beta/*.* $(WEBSAMPLEBETA)
-upload_relnotes:
- python ci/upload_relnotes.py CHANGES.rst pypi/coverage
+upload_relnotes: docreqs
+ $(SPHINXBUILD) -b rst doc /tmp/rst_rst
+ python ci/upload_relnotes.py /tmp/rst_rst/changes.rst pypi/coverage
diff --git a/doc/conf.py b/doc/conf.py
index 836f77c9..4baf66ac 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -35,6 +35,7 @@ extensions = [
'sphinx.ext.ifconfig',
'sphinxcontrib.spelling',
'sphinx.ext.intersphinx',
+ 'sphinx_rst_builder',
]
# Add any paths that contain templates here, relative to this directory.
diff --git a/doc/requirements.pip b/doc/requirements.pip
index 3f864737..28777cb5 100644
--- a/doc/requirements.pip
+++ b/doc/requirements.pip
@@ -5,5 +5,6 @@
doc8==0.8.0
pyenchant==2.0.0
sphinx==2.1.2
+sphinx-rst-builder==0.0.1
sphinxcontrib-spelling==4.3.0
sphinx_rtd_theme==0.4.3