Skip to content

Comments

ci: add typos spell checker workflow#146

Closed
Kunal1522 wants to merge 3 commits intom-lab:mainfrom
Kunal1522:ci/spellcheck
Closed

ci: add typos spell checker workflow#146
Kunal1522 wants to merge 3 commits intom-lab:mainfrom
Kunal1522:ci/spellcheck

Conversation

@Kunal1522
Copy link
Contributor

Summary

Adds a spell checking CI job using crate-ci/typos that runs on every push to main and every pull request.

Changes

  • .github/workflows/spelling.yml — single workflow file, no extra config files

Design

  • extend_words input used to whitelist M-Lab specific terms (mlab, msak, ndt, ndt7, oti) inline — avoids needing a separate _typos.toml
  • Pinned to crate-ci/typos@v1.29.10 for reproducibility
  • Concurrency group to cancel redundant runs on rapid pushes
  • timeout-minutes: 5 — typos completes in seconds

Why typos

  • Rust-based — extremely fast, no runtime to install
  • Catches common misspellings in code, comments, and docs
  • Used widely in major OSS projects (e.g., Linux kernel, curl)
  • No false positives on variable names (it understands code identifiers)

Notes

Add a dedicated workflow that runs actionlint on all .github/workflows/
YAML files to catch syntax errors, invalid expressions, and
misconfigured actions before they reach main.

Key behaviours:
- Only triggers when workflow files change (paths filter)
- Pinned to actionlint@v1.7.7 for reproducibility
- Concurrency group cancels redundant runs on rapid pushes
- 5 minute timeout — lint should never hang
Add a spell check CI job using crate-ci/typos that runs on every
push to main and every pull request.

M-Lab specific terms (mlab, msak, ndt, ndt7, oti) are whitelisted
via the extend_words input to prevent false positives.

typos is a fast Rust-based spell checker that catches common
misspellings in source code, comments, and documentation without
requiring any extra tooling or config files.
Replace separate spelling.yml with a unified lint.yml that runs
both actionlint and cspell as parallel jobs.

- actionlint: validates GitHub Actions workflow YAML syntax
- cspell: spell checks all source files using actual dictionaries
  (used by OWASP NestJS, VS Code, TypeScript)

cspell config is inline via inline_config — no separate .cspell.json
needed. M-Lab specific terms and tool names are whitelisted in the
words array.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant