From 6de8633065566ff6e696092615473831565df029 Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Tue, 2 Feb 2021 12:43:11 +0000 Subject: [PATCH 01/15] Only run bats diagnostics on failure (#24) * Only run bats diagnostics on failure * Try a different failure syntax * Third time lucky? * Always run if we failed, even though the previous step failed As per https://github.com/actions/runner/issues/491 * Try and fix the logic again * Simplify the testing * Try a different way of checking for failure * Try matching on any status, is matrix confusing things? * Drop the matrix for now * Fix the workflow syntax * Different variable name * Undo the hacking, matrix the bats tests * Actually run bats if we need to * Undo the deliberate test breakage --- .github/workflows/testing.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 697e178..34c4219 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -63,16 +63,22 @@ jobs: diagnose_bats: name: Diagnose bats + needs: test + if: always() && needs.test.result == 'failure' runs-on: ubuntu-latest continue-on-error: true + strategy: + fail-fast: false + matrix: + codespell_pip_version: ['codespell'] + include: + - codespell_pip_version: 'git+https://github.com/codespell-project/codespell.git' steps: - uses: actions/checkout@v1 - name: Set up Python uses: actions/setup-python@v2 - - run: pip3 --quiet --quiet install git+https://github.com/codespell-project/codespell.git + - run: pip3 --quiet --quiet install ${{ matrix.codespell_pip_version }} - run: | - # Skip the bats diagnostics - exit 0 # Simulate the Dockerfile COPY command [ -d "${RUNNER_TEMP}/code/" ] || sudo mkdir -p ${RUNNER_TEMP}/code/ [ -f "${RUNNER_TEMP}/code/codespell-matcher.json" ] || sudo cp codespell-problem-matcher/codespell-matcher.json ${RUNNER_TEMP}/code/ From de089481bd65b71b4d02e34ffb3566b6d189333e Mon Sep 17 00:00:00 2001 From: Peter Newman Date: Tue, 27 Apr 2021 16:01:06 +0100 Subject: [PATCH 02/15] Update README (#30) * Update README Add more parameters already in actions.yml * Add note about case sensitivity of words to actions.yml * Switch to a deliberate typo we're already using * Check our README separately ignoring the two intentional typos * Self censor ourselves! --- .github/workflows/testing.yml | 9 ++++++++- README.md | 38 +++++++++++++++++++++++++++++++++++ action.yml | 4 ++-- 3 files changed, 48 insertions(+), 3 deletions(-) diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 34c4219..06d8410 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -59,7 +59,14 @@ jobs: check_filenames: true check_hidden: true # When using this Action in other repos, the --skip option below can be removed - skip: ./.git,./codespell-problem-matcher/test,./test + skip: ./.git,./codespell-problem-matcher/test,./test,./README.md,./.github/workflows/testing.yml + # Check our README (and this workflow) ignoring the two intentional typos + - uses: ./ + with: + check_filenames: true + check_hidden: true + path: ./README.md,./.github/workflows/testing.yml + ignore_words_list: abandonned,ackward diagnose_bats: name: Diagnose bats diff --git a/README.md b/README.md index 86ec47a..898039b 100644 --- a/README.md +++ b/README.md @@ -57,6 +57,44 @@ with: skip: foo,bar ``` +### Parameter: builtin + +Comma-separated list of builtin dictionaries to use. + +This parameter is optional; by default `codespell` will use it's default selection of built in dictionaries. + +``` +uses: codespell-project/actions-codespell@master +with: + builtin: clear,rare +``` + +### Parameter: ignore_words_file + +File that contains words which will be ignored by `codespell`. File must contain one word per line. +Words are case sensitive based on how they are written in the dictionary file. + +This parameter is optional; by default `codespell` will check all words for typos. + +``` +uses: codespell-project/actions-codespell@master +with: + ignore_words_file: .codespellignore +``` + +### Parameter: ignore_words_list + +Comma-separated list of words which will be ignored by `codespell`. +Words are case sensitive based on how they are written in the dictionary file. + +This parameter is optional; by default `codespell` will check all words for typos. + +``` +uses: codespell-project/actions-codespell@master +with: + ignore_words_list: abandonned,ackward +``` + ### Parameter: path Indicates the path to run `codespell` in. diff --git a/action.yml b/action.yml index e900b00..522d9cf 100644 --- a/action.yml +++ b/action.yml @@ -23,11 +23,11 @@ inputs: required: false default: '' ignore_words_file: - description: 'File with a list of words to be ignored' + description: 'File with a list of words to be ignored. Words are case sensitive based on how they are written in the dictionary file' required: false default: '' ignore_words_list: - description: 'Comma-separated list of words to be ignored' + description: 'Comma-separated list of words to be ignored. Words are case sensitive based on how they are written in the dictionary file' required: false default: '' path: From 178af50561d01bb03eec45a6459523981345b18f Mon Sep 17 00:00:00 2001 From: Dimitri Papadopoulos <3234522+DimitriPapadopoulos@users.noreply.github.com> Date: Fri, 17 Sep 2021 14:28:43 +0200 Subject: [PATCH 03/15] Fix typo --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 898039b..df04849 100644 --- a/README.md +++ b/README.md @@ -61,7 +61,7 @@ with: Comma-separated list of builtin dictionaries to use. -This parameter is optional; by default `codespell` will use it's default selection of built in dictionaries. +This parameter is optional; by default `codespell` will use its default selection of built in dictionaries. ``` uses: codespell-project/actions-codespell@master From 22ff5a2e4b591290baf82d47c9feadac31c65441 Mon Sep 17 00:00:00 2001 From: Daniel McCloy Date: Thu, 18 Aug 2022 15:09:11 -0500 Subject: [PATCH 04/15] add uri_ignore_words_list option (#46) --- README.md | 14 ++++++++++++++ action.yml | 4 ++++ entrypoint.sh | 4 ++++ test/test.bats | 16 ++++++++++++++-- test/testdata/example.txt | 1 + 5 files changed, 37 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index df04849..1a1b03e 100644 --- a/README.md +++ b/README.md @@ -95,6 +95,20 @@ with: ignore_words_list: abandonned,ackward ``` +### Parameter: uri_ignore_words_list + +Comma-separated list of words which will be ignored by `codespell` in URIs and emails only. +Words are case sensitive based on how they are written in the dictionary file. +If set to "*", all misspelling in URIs and emails will be ignored. + +This parameter is optional; by default `codespell` will check all URIs and emails for typos. + +``` +uses: codespell-project/actions-codespell@master +with: + uri_ignore_words_list: abandonned +``` + ### Parameter: path Indicates the path to run `codespell` in. diff --git a/action.yml b/action.yml index 522d9cf..59e4372 100644 --- a/action.yml +++ b/action.yml @@ -30,6 +30,10 @@ inputs: description: 'Comma-separated list of words to be ignored. Words are case sensitive based on how they are written in the dictionary file' required: false default: '' + uri_ignore_words_list: + description: 'comma separated list of words to be ignored in URIs and emails only' + required: false + default: '' path: description: 'Path to run codespell in' required: false diff --git a/entrypoint.sh b/entrypoint.sh index 0fc188f..7c3d4ed 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -40,6 +40,10 @@ echo "Ignore words list '${INPUT_IGNORE_WORDS_LIST}'" if [ "x${INPUT_IGNORE_WORDS_LIST}" != "x" ]; then command_args="${command_args} --ignore-words-list ${INPUT_IGNORE_WORDS_LIST}" fi +echo "Ignore URI words list '${INPUT_URI_IGNORE_WORDS_LIST}'" +if [ "x${INPUT_URI_IGNORE_WORDS_LIST}" != "x" ]; then + command_args="${command_args} --uri-ignore-words-list ${INPUT_URI_IGNORE_WORDS_LIST}" +fi echo "Resulting CLI options ${command_args}" exec 5>&1 res=`{ { codespell --count ${command_args} ${INPUT_PATH}; echo $? 1>&4; } 1>&5; } 4>&1` diff --git a/test/test.bats b/test/test.bats index db7ac8f..119bc5b 100644 --- a/test/test.bats +++ b/test/test.bats @@ -7,12 +7,13 @@ # This currently breaks the tests, so only enabling when troubleshooting #load teardown -ROOT_MISSPELLING_COUNT=5 +ROOT_MISSPELLING_COUNT=6 FILENAME_MISSPELLING_COUNT=1 HIDDEN_MISSPELLING_COUNT=1 EXCLUDED_MISSPELLING_COUNT=1 BUILTIN_NAMES_MISSPELLING_COUNT=1 IGNORE_WORDS_MISSPELLING_COUNT=5 +URI_IGNORE_WORDS_MISSPELLING_COUNT=1 SUBFOLDER_MISSPELLING_COUNT=1 # From all files called example.txt EXAMPLE_MISSPELLING_COUNT=5 @@ -40,6 +41,7 @@ function setup() { export INPUT_BUILTIN="" export INPUT_IGNORE_WORDS_FILE="" export INPUT_IGNORE_WORDS_LIST="" + export INPUT_URI_IGNORE_WORDS_LIST="" export INPUT_PATH="./test/testdata" export INPUT_ONLY_WARN="" } @@ -103,7 +105,7 @@ function setup() { } @test "Check the skip option" { - errorCount=$((ROOT_MISSPELLING_COUNT + SUBFOLDER_MISSPELLING_COUNT - EXAMPLE_MISSPELLING_COUNT)) + errorCount=$((ROOT_MISSPELLING_COUNT + SUBFOLDER_MISSPELLING_COUNT - EXAMPLE_MISSPELLING_COUNT - URI_IGNORE_WORDS_MISSPELLING_COUNT)) # codespell's exit status is 0, or 65 if there are errors found if [ $errorCount -eq 0 ]; then expectedExitStatus=0; else expectedExitStatus=65; fi INPUT_SKIP="example.txt" @@ -142,6 +144,16 @@ function setup() { [ "${lines[-4 - $errorCount]}" == "$errorCount" ] } +@test "Use a URI ignore words list" { + errorCount=$((ROOT_MISSPELLING_COUNT + SUBFOLDER_MISSPELLING_COUNT - URI_IGNORE_WORDS_MISSPELLING_COUNT)) + # codespell's exit status is 0, or 65 if there are errors found + if [ $errorCount -eq 0 ]; then expectedExitStatus=0; else expectedExitStatus=65; fi + INPUT_URI_IGNORE_WORDS_LIST="bu" + run "./entrypoint.sh" + [ $status -eq $expectedExitStatus ] + [ "${lines[-4 - $errorCount]}" == "$errorCount" ] +} + @test "Custom path" { errorCount=$((SUBFOLDER_MISSPELLING_COUNT)) # codespell's exit status is 0, or 65 if there are errors found diff --git a/test/testdata/example.txt b/test/testdata/example.txt index e1118f6..f27e93b 100644 --- a/test/testdata/example.txt +++ b/test/testdata/example.txt @@ -2,3 +2,4 @@ Abandonned ABANDONNED AbAnDoNnEd +https://www.bu.edu From be0a4143f6f699cb57ca9ce4c4d423edd06912ac Mon Sep 17 00:00:00 2001 From: Dimitri Papadopoulos <3234522+DimitriPapadopoulos@users.noreply.github.com> Date: Mon, 26 Sep 2022 13:46:09 +0200 Subject: [PATCH 05/15] Update GitHub Actions --- .github/workflows/publish_master.yml | 2 +- .github/workflows/publish_stable.yml | 2 +- .github/workflows/testing.yml | 12 ++++++------ 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/publish_master.yml b/.github/workflows/publish_master.yml index b3c89b7..7e2ebd8 100644 --- a/.github/workflows/publish_master.yml +++ b/.github/workflows/publish_master.yml @@ -13,7 +13,7 @@ jobs: name: Publish master image runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v3 - name: Build run: | GITHUB_REPOSITORY_LC=$(echo "${GITHUB_REPOSITORY}" | tr [A-Z] [a-z]) diff --git a/.github/workflows/publish_stable.yml b/.github/workflows/publish_stable.yml index d787bd9..18283fc 100644 --- a/.github/workflows/publish_stable.yml +++ b/.github/workflows/publish_stable.yml @@ -10,7 +10,7 @@ jobs: name: Publish stable image runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v3 - name: Build run: | GITHUB_REPOSITORY_LC=$(echo "${GITHUB_REPOSITORY}" | tr [A-Z] [a-z]) diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 06d8410..1dea6fb 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -19,10 +19,10 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 - name: Install codespell via pip using ${{ matrix.codespell_pip_version }} run: pip3 --quiet --quiet install ${{ matrix.codespell_pip_version }} @@ -43,7 +43,7 @@ jobs: name: Test run action runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: ./ with: path: test/testdata @@ -53,7 +53,7 @@ jobs: name: Check for spelling errors runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: ./ with: check_filenames: true @@ -81,9 +81,9 @@ jobs: include: - codespell_pip_version: 'git+https://github.com/codespell-project/codespell.git' steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v3 - name: Set up Python - uses: actions/setup-python@v2 + uses: actions/setup-python@v4 - run: pip3 --quiet --quiet install ${{ matrix.codespell_pip_version }} - run: | # Simulate the Dockerfile COPY command From 4ab5346f1bc9992edd996d458422c19c086c8c05 Mon Sep 17 00:00:00 2001 From: per1234 Date: Mon, 26 Sep 2022 19:42:26 -0700 Subject: [PATCH 06/15] Configure Dependabot to check for outdated actions used in workflows Dependabot will periodically check the versions of all actions used in the repository's workflows. If any are found to be outdated, it will submit a pull request to update them. --- .github/dependabot.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..fd83b11 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,10 @@ +# See: https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#about-the-dependabotyml-file +version: 2 + +updates: + # Configure check for outdated GitHub Actions actions in workflows. + # See: https://docs.github.com/code-security/dependabot/working-with-dependabot/keeping-your-actions-up-to-date-with-dependabot + - package-ecosystem: github-actions + directory: / # Check the repository's workflows under /.github/workflows/ + schedule: + interval: daily From 9c63fddd79f483308bfaea379a505dcd361b5d1d Mon Sep 17 00:00:00 2001 From: Jon Dufresne Date: Mon, 2 Jan 2023 10:02:42 -0800 Subject: [PATCH 07/15] Encourage the use of semantic versioning in the README (#58) Follow community practices by recommending semantic versioning so changes to actions-codespell does not break workflows. For example, the actions/checkout does the same: https://github.com/actions/checkout --- README.md | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index 1a1b03e..ea4dcc1 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ Any warnings or errors will be annotated in the Pull Request. ## Usage ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 ``` ### Parameter: check_filenames @@ -16,7 +16,7 @@ If set, check file names for spelling mistakes as well. This parameter is optional; by default `codespell` will only check the file contents. ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 with: check_filenames: true ``` @@ -28,7 +28,7 @@ If set, check hidden files (those starting with ".") for spelling mistakes as we This parameter is optional; by default `codespell` will not check hidden files. ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 with: check_hidden: true ``` @@ -40,7 +40,7 @@ File with lines that should not be checked for spelling mistakes. This parameter is optional; by default `codespell` will check all lines. ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 with: exclude_file: src/foo ``` @@ -52,7 +52,7 @@ Comma-separated list of files to skip (it accepts globs as well). This parameter is optional; by default `codespell` won't skip any files. ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 with: skip: foo,bar ``` @@ -64,7 +64,7 @@ Comma-separated list of builtin dictionaries to use. This parameter is optional; by default `codespell` will use its default selection of built in dictionaries. ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 with: builtin: clear,rare ``` @@ -77,7 +77,7 @@ Words are case sensitive based on how they are written in the dictionary file. This parameter is optional; by default `codespell` will check all words for typos. ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 with: ignore_words_file: .codespellignore ``` @@ -90,7 +90,7 @@ Words are case sensitive based on how they are written in the dictionary file. This parameter is optional; by default `codespell` will check all words for typos. ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 with: ignore_words_list: abandonned,ackward ``` @@ -104,7 +104,7 @@ If set to "*", all misspelling in URIs and emails will be ignored. This parameter is optional; by default `codespell` will check all URIs and emails for typos. ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 with: uri_ignore_words_list: abandonned ``` @@ -117,7 +117,7 @@ This can be useful if your project has code you don't want to spell check for so This parameter is optional; by default `codespell` will run on your whole repository. ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 with: path: src ``` @@ -131,7 +131,7 @@ All errors and warnings are annotated in Pull Requests, but it will act like eve This parameter is optional; setting this to any value will enable it. ``` -uses: codespell-project/actions-codespell@master +uses: codespell-project/actions-codespell@v1 with: only_warn: 1 ``` From 9b834d8dfe6818d6cbf4f47627b48691ce11dc7e Mon Sep 17 00:00:00 2001 From: Eric Larson Date: Wed, 29 Mar 2023 09:18:54 -0600 Subject: [PATCH 08/15] ENH: Enable use of pyproject.toml (#60) * ENH: Enable use of pyproject.toml * FIX: Try a fix * FIX: Again --- .github/workflows/testing.yml | 7 ++++++- requirements.txt | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 1dea6fb..554eafe 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -23,9 +23,14 @@ jobs: - name: Set up Python uses: actions/setup-python@v4 + with: + python-version: '3.10' - name: Install codespell via pip using ${{ matrix.codespell_pip_version }} - run: pip3 --quiet --quiet install ${{ matrix.codespell_pip_version }} + run: pip install ${{ matrix.codespell_pip_version }} + + - name: Check codespell + run: codespell --version - name: Install Bats run: | diff --git a/requirements.txt b/requirements.txt index 84d2ed8..291f885 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1 +1 @@ -codespell>=2.0.0 +codespell[toml]>=2.2.4 From 57beb9f38f49d773d641ac555d1565c3b6a59938 Mon Sep 17 00:00:00 2001 From: Christian Clauss Date: Wed, 29 Mar 2023 18:26:33 +0200 Subject: [PATCH 09/15] Upgrade GitHub Actions setup-python (#61) https://github.com/actions/setup-python/releases --- codespell-problem-matcher/.github/workflows/test.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/codespell-problem-matcher/.github/workflows/test.yml b/codespell-problem-matcher/.github/workflows/test.yml index 5116018..39afde8 100644 --- a/codespell-problem-matcher/.github/workflows/test.yml +++ b/codespell-problem-matcher/.github/workflows/test.yml @@ -25,7 +25,9 @@ jobs: steps: - name: Checkout uses: actions/checkout@master - - uses: actions/setup-python@v1 + - uses: actions/setup-python@v4 + with: + python-version:3.x - run: pip install git+https://github.com/codespell-project/codespell.git - uses: ./ - name: Check codespell From 94259cd8be02ad2903ba34a22d9c13de21a74461 Mon Sep 17 00:00:00 2001 From: Hugo van Kemenade Date: Fri, 28 Apr 2023 16:14:47 +0300 Subject: [PATCH 10/15] Add syntax highlighting for readability (#64) --- README.md | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index ea4dcc1..2c845ce 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ Any warnings or errors will be annotated in the Pull Request. ## Usage -``` +```yml uses: codespell-project/actions-codespell@v1 ``` @@ -15,7 +15,7 @@ If set, check file names for spelling mistakes as well. This parameter is optional; by default `codespell` will only check the file contents. -``` +```yml uses: codespell-project/actions-codespell@v1 with: check_filenames: true @@ -27,7 +27,7 @@ If set, check hidden files (those starting with ".") for spelling mistakes as we This parameter is optional; by default `codespell` will not check hidden files. -``` +```yml uses: codespell-project/actions-codespell@v1 with: check_hidden: true @@ -39,7 +39,7 @@ File with lines that should not be checked for spelling mistakes. This parameter is optional; by default `codespell` will check all lines. -``` +```yml uses: codespell-project/actions-codespell@v1 with: exclude_file: src/foo @@ -51,7 +51,7 @@ Comma-separated list of files to skip (it accepts globs as well). This parameter is optional; by default `codespell` won't skip any files. -``` +```yml uses: codespell-project/actions-codespell@v1 with: skip: foo,bar @@ -63,7 +63,7 @@ Comma-separated list of builtin dictionaries to use. This parameter is optional; by default `codespell` will use its default selection of built in dictionaries. -``` +```yml uses: codespell-project/actions-codespell@v1 with: builtin: clear,rare @@ -76,7 +76,7 @@ Words are case sensitive based on how they are written in the dictionary file. This parameter is optional; by default `codespell` will check all words for typos. -``` +```yml uses: codespell-project/actions-codespell@v1 with: ignore_words_file: .codespellignore @@ -89,7 +89,7 @@ Words are case sensitive based on how they are written in the dictionary file. This parameter is optional; by default `codespell` will check all words for typos. -``` +```yml uses: codespell-project/actions-codespell@v1 with: ignore_words_list: abandonned,ackward @@ -103,7 +103,7 @@ If set to "*", all misspelling in URIs and emails will be ignored. This parameter is optional; by default `codespell` will check all URIs and emails for typos. -``` +```yml uses: codespell-project/actions-codespell@v1 with: uri_ignore_words_list: abandonned @@ -116,7 +116,7 @@ This can be useful if your project has code you don't want to spell check for so This parameter is optional; by default `codespell` will run on your whole repository. -``` +```yml uses: codespell-project/actions-codespell@v1 with: path: src @@ -130,7 +130,7 @@ All errors and warnings are annotated in Pull Requests, but it will act like eve This parameter is optional; setting this to any value will enable it. -``` +```yml uses: codespell-project/actions-codespell@v1 with: only_warn: 1 From 41170f1b9c4f5c5788cb677c6c2f9ef26010243d Mon Sep 17 00:00:00 2001 From: OKURA Masafumi Date: Fri, 18 Aug 2023 20:46:11 +0900 Subject: [PATCH 11/15] Use v2 in README (#69) It looks like v2 is already released, so README should point it instead of v1. --- README.md | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index 2c845ce..84597fc 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ Any warnings or errors will be annotated in the Pull Request. ## Usage ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 ``` ### Parameter: check_filenames @@ -16,7 +16,7 @@ If set, check file names for spelling mistakes as well. This parameter is optional; by default `codespell` will only check the file contents. ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 with: check_filenames: true ``` @@ -28,7 +28,7 @@ If set, check hidden files (those starting with ".") for spelling mistakes as we This parameter is optional; by default `codespell` will not check hidden files. ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 with: check_hidden: true ``` @@ -40,7 +40,7 @@ File with lines that should not be checked for spelling mistakes. This parameter is optional; by default `codespell` will check all lines. ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 with: exclude_file: src/foo ``` @@ -52,7 +52,7 @@ Comma-separated list of files to skip (it accepts globs as well). This parameter is optional; by default `codespell` won't skip any files. ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 with: skip: foo,bar ``` @@ -64,7 +64,7 @@ Comma-separated list of builtin dictionaries to use. This parameter is optional; by default `codespell` will use its default selection of built in dictionaries. ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 with: builtin: clear,rare ``` @@ -77,7 +77,7 @@ Words are case sensitive based on how they are written in the dictionary file. This parameter is optional; by default `codespell` will check all words for typos. ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 with: ignore_words_file: .codespellignore ``` @@ -90,7 +90,7 @@ Words are case sensitive based on how they are written in the dictionary file. This parameter is optional; by default `codespell` will check all words for typos. ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 with: ignore_words_list: abandonned,ackward ``` @@ -104,7 +104,7 @@ If set to "*", all misspelling in URIs and emails will be ignored. This parameter is optional; by default `codespell` will check all URIs and emails for typos. ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 with: uri_ignore_words_list: abandonned ``` @@ -117,7 +117,7 @@ This can be useful if your project has code you don't want to spell check for so This parameter is optional; by default `codespell` will run on your whole repository. ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 with: path: src ``` @@ -131,7 +131,7 @@ All errors and warnings are annotated in Pull Requests, but it will act like eve This parameter is optional; setting this to any value will enable it. ```yml -uses: codespell-project/actions-codespell@v1 +uses: codespell-project/actions-codespell@v2 with: only_warn: 1 ``` From 8dc81685022bbd5008e21ddb6f44abe4eb4f27b1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 5 Sep 2023 08:56:10 -0400 Subject: [PATCH 12/15] Bump actions/checkout from 3 to 4 (#72) Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/publish_master.yml | 2 +- .github/workflows/publish_stable.yml | 2 +- .github/workflows/testing.yml | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/publish_master.yml b/.github/workflows/publish_master.yml index 7e2ebd8..f38f0de 100644 --- a/.github/workflows/publish_master.yml +++ b/.github/workflows/publish_master.yml @@ -13,7 +13,7 @@ jobs: name: Publish master image runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Build run: | GITHUB_REPOSITORY_LC=$(echo "${GITHUB_REPOSITORY}" | tr [A-Z] [a-z]) diff --git a/.github/workflows/publish_stable.yml b/.github/workflows/publish_stable.yml index 18283fc..4aabefa 100644 --- a/.github/workflows/publish_stable.yml +++ b/.github/workflows/publish_stable.yml @@ -10,7 +10,7 @@ jobs: name: Publish stable image runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Build run: | GITHUB_REPOSITORY_LC=$(echo "${GITHUB_REPOSITORY}" | tr [A-Z] [a-z]) diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 554eafe..3c8f25b 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -19,7 +19,7 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Set up Python uses: actions/setup-python@v4 @@ -48,7 +48,7 @@ jobs: name: Test run action runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./ with: path: test/testdata @@ -58,7 +58,7 @@ jobs: name: Check for spelling errors runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: ./ with: check_filenames: true @@ -86,7 +86,7 @@ jobs: include: - codespell_pip_version: 'git+https://github.com/codespell-project/codespell.git' steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up Python uses: actions/setup-python@v4 - run: pip3 --quiet --quiet install ${{ matrix.codespell_pip_version }} From 8edd9f294002b35e8d7de67b06ac493e89114b91 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 7 Dec 2023 14:49:50 -0500 Subject: [PATCH 13/15] Bump actions/setup-python from 4 to 5 (#74) Bumps [actions/setup-python](https://github.com/actions/setup-python) from 4 to 5. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](https://github.com/actions/setup-python/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/setup-python dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/testing.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 3c8f25b..097f442 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -22,7 +22,7 @@ jobs: uses: actions/checkout@v4 - name: Set up Python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: '3.10' @@ -88,7 +88,7 @@ jobs: steps: - uses: actions/checkout@v4 - name: Set up Python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 - run: pip3 --quiet --quiet install ${{ matrix.codespell_pip_version }} - run: | # Simulate the Dockerfile COPY command From 3174815d6231f5bdc24dbfb6fc3b8caec73d521c Mon Sep 17 00:00:00 2001 From: "K.B.Dharun Krishna" Date: Tue, 27 Feb 2024 00:43:18 +0530 Subject: [PATCH 14/15] feat: bump to use node20 runtime (#71) * feat: bump to use node20 runtime, actions/checkout to v4 * Setup pre-commit to run codespell Eat our own dogfood... * codespell --skip="abandonned,ackward,bu" * codespell --ignore-words-list="abandonned,ackward,bu" * Update testing.yml --------- Co-authored-by: Christian Clauss --- .github/workflows/testing.yml | 2 +- .pre-commit-config.yaml | 8 ++++++++ codespell-problem-matcher/action.yml | 2 +- 3 files changed, 10 insertions(+), 2 deletions(-) create mode 100644 .pre-commit-config.yaml diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 097f442..62ca0bf 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -64,7 +64,7 @@ jobs: check_filenames: true check_hidden: true # When using this Action in other repos, the --skip option below can be removed - skip: ./.git,./codespell-problem-matcher/test,./test,./README.md,./.github/workflows/testing.yml + skip: ./.git,./codespell-problem-matcher/test,./test,./README.md,./.github/workflows/testing.yml,./.pre-commit-config.yaml # Check our README (and this workflow) ignoring the two intentional typos - uses: ./ with: diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000..927bd3d --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,8 @@ +repos: + - repo: https://github.com/codespell-project/codespell + rev: v2.2.6 + hooks: + - id: codespell + args: [--ignore-words-list, "abandonned,ackward,bu"] + additional_dependencies: + - tomli diff --git a/codespell-problem-matcher/action.yml b/codespell-problem-matcher/action.yml index 6d34e83..eb40b8d 100644 --- a/codespell-problem-matcher/action.yml +++ b/codespell-problem-matcher/action.yml @@ -2,7 +2,7 @@ name: 'codespell problem matcher' author: 'Peter Newman' description: 'Shows codespell errors as annotation (with file and code line) in GitHub Actions' runs: - using: 'node12' + using: 'node20' main: 'index.js' branding: icon: 'search' From 406322ec52dd7b488e48c1c4b82e2a8b3a1bf630 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 28 May 2024 09:10:51 -0400 Subject: [PATCH 15/15] [pre-commit.ci] pre-commit autoupdate (#76) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/codespell-project/codespell: v2.2.6 → v2.3.0](https://github.com/codespell-project/codespell/compare/v2.2.6...v2.3.0) Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 927bd3d..4c71139 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/codespell-project/codespell - rev: v2.2.6 + rev: v2.3.0 hooks: - id: codespell args: [--ignore-words-list, "abandonned,ackward,bu"]