From 69a76e32b7141d05e4d8f006a10ef8ed1ef87bd2 Mon Sep 17 00:00:00 2001 From: Nils <52573120+niStee@users.noreply.github.com> Date: Sun, 14 Sep 2025 08:20:51 +0200 Subject: [PATCH] chore(pre-commit): add typos with conservative excludes; no content changes (#1317) Co-authored-by: Gideon <87426140+GideonBear@users.noreply.github.com> Co-authored-by: niStee <52573120+niStee@users.noreply.github.comclear> --- .pre-commit-config.yaml | 5 +++++ .typos.toml | 20 ++++++++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 .typos.toml diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c9ba1d0c..7247d99e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -12,3 +12,8 @@ repos: hooks: - id: end-of-file-fixer - id: trailing-whitespace + +- repo: https://github.com/crate-ci/typos + rev: v1.36.2 + hooks: + - id: typos diff --git a/.typos.toml b/.typos.toml new file mode 100644 index 00000000..841ec3b3 --- /dev/null +++ b/.typos.toml @@ -0,0 +1,20 @@ +# Typos configuration (minimal, conservative) +# Exclude locales and OS fingerprint data to avoid false positives +# - Recognize a few project-specific proper nouns + +[files] +extend-exclude = [ + "src/steps/os/os_release/**", + "locales/**", + # Include only English locale files - TODO: Split locales/app.yml into a Separate english File + # "!locales/en/**" +] + +[default] +# Mark specific words as always valid by mapping them to themselves +check-file = true +check-filename = true + +[default.extend-words] +# Add project-specific terms that should not be flagged as typos +# Example: topgrade = "topgrade"