Skip to content

Commit

Permalink
ci: Add a typos check (#799)
Browse files Browse the repository at this point in the history
This can be run locally by installing `typos` from
<https://github.com/crate-ci/typos>.

Configuration is in `.typos.toml`.
  • Loading branch information
waywardmonkeys authored Jul 27, 2024
1 parent 5fc22b3 commit 38233eb
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -90,3 +90,12 @@ jobs:
- uses: taiki-e/install-action@nextest

- run: ci/nextest-compat.sh

# If this fails, consider changing your text or adding something to .typos.toml
typos:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: check typos
uses: crate-ci/[email protected]
22 changes: 22 additions & 0 deletions .typos.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# See the configuration reference at
# https://github.com/crate-ci/typos/blob/master/docs/reference.md

# Corrections take the form of a key/value pair. The key is the incorrect word
# and the value is the correct word. If the key and value are the same, the
# word is treated as always correct. If the value is an empty string, the word
# is treated as always incorrect.

# Match Identifier - Case Sensitive
[default.extend-identifiers]
Nd = "Nd"
thr = "thr"

# Match Inside a Word - Case Insensitive
[default.extend-words]

[files]
# Include .github, .cargo, etc.
ignore-hidden = false
# /.git isn't in .gitignore, because git never tracks it.
# Typos doesn't know that, though.
extend-exclude = ["/.git"]

0 comments on commit 38233eb

Please sign in to comment.