-
Notifications
You must be signed in to change notification settings - Fork 107
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Sergei Petrosian <[email protected]>
- Loading branch information
Showing
4 changed files
with
38 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
[codespell] | ||
# Ref: https://github.com/codespell-project/codespell#using-a-config-file | ||
skip = tests,artifacts*,pylintrc | ||
builtin = usage | ||
ignore-multiline-regex = codespell:ignore-begin.*codespell:ignore-end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Codespell configuration is within .codespellrc | ||
--- | ||
name: Codespell | ||
on: # yamllint disable-line rule:truthy | ||
- pull_request | ||
permissions: | ||
contents: read | ||
jobs: | ||
codespell: | ||
name: Check for spelling errors | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Checkout repo | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install codespell | ||
run: pip install codespell | ||
|
||
- name: Get variable with regex values | ||
id: regexvar | ||
run: | | ||
curl -L -s -o dictionary_usage.txt https://raw.githubusercontent.com/codespell-project/codespell/refs/heads/main/codespell_lib/data/dictionary_usage.txt | ||
regexvar=$(sed 's/->.*//g' dictionary_usage.txt | sed 's/$/|/' | tr -d '\n' | sed 's/.$//') | ||
echo "$regexvar" | ||
echo "regexvar=$regexvar" >> "$GITHUB_OUTPUT" | ||
- name: Run codespell | ||
run: codespell tasks/main.yml --regex "${{ steps.regexvar.outputs.regexvar }}" -C0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters