Skip to content

Commit

Permalink
CI: Set up codespell and add to the linting tools (Fixes #714)
Browse files Browse the repository at this point in the history
  • Loading branch information
dopplershift committed Jul 1, 2021
1 parent bb98358 commit fd72202
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 1 deletion.
12 changes: 11 additions & 1 deletion .github/workflows/linting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
with:
python-version: 3.x

- name: Install flake8
- name: Install linting tools
run: python -m pip install -r ci/linting_requirements.txt

- name: Set up reviewdog
Expand All @@ -40,4 +40,14 @@ jobs:
env:
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
set -o pipefail
doc8 docs | reviewdog -efm='%f:%l: %m' -name=doc8 -reporter=github-check -filter-mode=nofilter
- name: Run codespell
# Don't skip codespell if any other steps fail
if: ${{ always() }}
env:
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
set -o pipefail
codespell | reviewdog -efm='%f:%l: %m' -name=codespell -reporter=github-check -filter-mode=nofilter
2 changes: 2 additions & 0 deletions ci/linting_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,5 @@ pydocstyle==6.1.1

doc8==0.8.1
restructuredtext_lint==1.3.2

codespell==2.1.0
4 changes: 4 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -113,3 +113,7 @@ max-line-length = 95
match = (?!(test_|setup)).*\.py
match-dir = (?!(build|docs|examples|tutorials|_nexrad_msgs))[^.].*
convention = numpy

[codespell]
skip = *.tbl,*.ipynb,AUTHORS.txt,gempak.rst,.git,./staticdata,./docs/build
ignore-words-list = pres,thta

0 comments on commit fd72202

Please sign in to comment.