From 120669996937515d91e61fc518a960ff2529d7d0 Mon Sep 17 00:00:00 2001 From: Koichi ITO Date: Thu, 25 Nov 2021 21:04:32 +0900 Subject: [PATCH] Add spell checking GitHub Actions workflow Follow up to https://github.com/rubocop/rubocop/pull/10128. This PR adds spell checking GitHub Actions workflow. --- .github/workflows/spell_checking.yml | 33 ++++++++++++++++++++++++++++ codespell.txt | 3 +++ 2 files changed, 36 insertions(+) create mode 100644 .github/workflows/spell_checking.yml create mode 100644 codespell.txt diff --git a/.github/workflows/spell_checking.yml b/.github/workflows/spell_checking.yml new file mode 100644 index 00000000..55e8919b --- /dev/null +++ b/.github/workflows/spell_checking.yml @@ -0,0 +1,33 @@ +name: Spell Checking + +on: [pull_request] + +jobs: + codespell: + name: Check spelling with codespell + runs-on: ubuntu-latest + strategy: + matrix: + python-version: [3.8] + steps: + - uses: actions/checkout@v2 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install codespell + if [ -f requirements.txt ]; then pip install -r requirements.txt; fi + - name: Check spelling with codespell + run: codespell --ignore-words=codespell.txt || exit 1 + misspell: + name: Check spelling with misspell + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Install + run: wget -O - -q https://git.io/misspell | sh -s -- -b . + - name: Misspell + run: ./misspell -error diff --git a/codespell.txt b/codespell.txt new file mode 100644 index 00000000..e1132b96 --- /dev/null +++ b/codespell.txt @@ -0,0 +1,3 @@ +revered +rouge +sting