From a4eb4eb42be5b2b7f401f51baf8c0863f54fe63d Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Thu, 7 May 2020 00:07:38 -0400 Subject: [PATCH] Fix markdownlint test (#2095) Travis only gives us Node.js version 8 so we must use an older version of markdownlint. To declare a newer node.js version we lose the ability to have Python as the lang and install tox. If/when the default node version gets updated, remove the version restriction on markdownlint. --- .travis.yml | 7 ++++++- docs/user-guide/custom-themes.md | 2 +- tox.ini | 9 +++++++-- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/.travis.yml b/.travis.yml index 8c3e7d22..d733a19e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -7,7 +7,12 @@ matrix: # Default Python - env: TOXENV=flake8 - env: TOXENV=markdown-lint - before_install: npm install -g markdownlint-cli + # Travis only gives us Node.js version 8 so we must use an older + # version of markdownlint. To declare a newer node.js version we + # lose the ability to have Python as the lang and install tox. + # If/when the default node version gets updated, remove the + # version restriction on markdownlint. + before_install: npm install -g markdownlint-cli@0.21.0 # Until Linkchecker is updated to Python 3, we will have skip this test. # Watch https://github.com/linkchecker/linkchecker for updates. # - env: TOXENV=linkchecker diff --git a/docs/user-guide/custom-themes.md b/docs/user-guide/custom-themes.md index e5003468..28a52e54 100644 --- a/docs/user-guide/custom-themes.md +++ b/docs/user-guide/custom-themes.md @@ -60,7 +60,7 @@ theme: !!! Warning - A theme's [configuration] defined in a `mkdocs_theme.yml` file is not loaded + A theme's [configuration] defined in a `mkdocs_theme.yml` file is not loaded from `theme.custom_dir`. When an entire theme exists in `theme.custom_dir` and `theme.name` is set to `null`, then the entire theme configuration must be defined in the [theme] configuration option in the `mkdocs.yml` file. diff --git a/tox.ini b/tox.ini index f9419186..e0b8a40e 100644 --- a/tox.ini +++ b/tox.ini @@ -20,9 +20,14 @@ deps=-rrequirements/test.txt commands={envbindir}/flake8 mkdocs --max-line-length=119 [testenv:markdown-lint] -whitelist_externals = markdownlint +whitelist_externals= + node + markdownlint passenv = * -commands=markdownlint README.md CONTRIBUTING.md docs/ +commands= + node --version + markdownlint --version + markdownlint README.md CONTRIBUTING.md docs/ --ignore docs/CNAME [testenv:linkchecker] basepython = python2.7