ci: add typos-cli

Given that typos are frequent and may appear in the public API spell
check code on CI.
This commit is contained in:
AmeKnite 2024-03-04 14:04:53 -06:00 committed by Kirill Chibisov
parent 4ade1a7518
commit b2f9fad654
7 changed files with 35 additions and 11 deletions

View file

@ -17,6 +17,24 @@ jobs:
- name: Check Formatting
run: cargo fmt -- --check
typos:
name: Check for typos
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
- uses: taiki-e/install-action@v2
with:
tool: typos-cli
- name: run typos
run: typos
- name: Typos info
if: failure()
run: |
echo 'To fix typos, please run `typos -w`'
echo 'To check for a diff, run `typos`'
echo 'You can find typos here: https://crates.io/crates/typos'
tests:
name: Test ${{ matrix.toolchain }} ${{ matrix.platform.name }}
runs-on: ${{ matrix.platform.os }}