From 189d1588870ae81bd0b6e7e91a037e6da8e6cc36 Mon Sep 17 00:00:00 2001 From: Cosimo Lupo Date: Tue, 21 Nov 2017 13:04:12 +0100 Subject: [PATCH] [travis/tox] check syntax of reStructuredText before release I pushed a NEWS.rst with broken indentation, the PyPI page will display plan text garbage. Next time I'll use docutils and do `python setup.py check --restructuredtext` before pushing a new tag. Also, I forgot to update .travis.yml to build the dist packages on python3.6 instead of 3.5 after I modified the tox.ini, so the automatic release from Travis failed. This time I had to use twine tool to upload the zip and whl packages from my local machine to PyPI. Sorry the mess... --- .travis.yml | 8 ++++---- NEWS.rst | 4 ++-- tox.ini | 4 ++++ 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/.travis.yml b/.travis.yml index ee8aed8bb..d8f20cb1c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,11 +10,11 @@ matrix: - python: 3.4 env: TOXENV=py34-cov - python: 3.5 - env: - - TOXENV=py35-cov - - BUILD_DIST=true + env: TOXENV=py35-cov - python: 3.6 - env: TOXENV=py36-cov + env: + - TOXENV=py36-cov + - BUILD_DIST=true - python: pypy2.7-5.8.0 # disable coverage.py on pypy because of performance problems env: TOXENV=pypy-nocov diff --git a/NEWS.rst b/NEWS.rst index 16bd7f373..ceb6d100c 100644 --- a/NEWS.rst +++ b/NEWS.rst @@ -16,8 +16,8 @@ ``pens.perimeterPen`` module (#1101). - [varLib] Started generating STAT table (8af4309). Right now it just reflects the axes, and even that with certain limitations: - * AxisOrdering is set to the order axes are defined, - * Name-table entries are not shared with fvar. + * AxisOrdering is set to the order axes are defined, + * Name-table entries are not shared with fvar. - [py23] Added backports for ``redirect_stdout`` and ``redirect_stderr`` context managers (#1097). - [Graphite] Fixed some round-trip bugs (#1093). diff --git a/tox.ini b/tox.ini index 9beff2542..cb1ab9158 100644 --- a/tox.ini +++ b/tox.ini @@ -46,6 +46,8 @@ commands = [testenv:bdist] basepython = {env:TOXPYTHON:python3.6} deps = + pygments + docutils setuptools wheel skip_install = true @@ -55,6 +57,8 @@ install_command = whitelist_externals = rm commands = + # check metadata and rst long_description + python setup.py check --restructuredtext --strict # clean up build/ and dist/ folders rm -rf {toxinidir}/dist python setup.py clean --all