From 2ee266c0d6ed087bcace4b0017d92cd35164dc4d Mon Sep 17 00:00:00 2001 From: morris Date: Mon, 25 Mar 2024 12:57:55 +0800 Subject: [PATCH] feat(pre-commit): add codespell to detect and fix typos --- .codespellrc | 4 ++++ .pre-commit-config.yaml | 4 ++++ 2 files changed, 8 insertions(+) create mode 100644 .codespellrc diff --git a/.codespellrc b/.codespellrc new file mode 100644 index 0000000000..44b6906ff1 --- /dev/null +++ b/.codespellrc @@ -0,0 +1,4 @@ +[codespell] +skip = build,*.yuv +ignore-words-list = ser,dout,rsource +write-changes = true diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 55308fbfc9..e9f8b82306 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -51,6 +51,10 @@ repos: (?x)^( .*_pb2.py )$ + - repo: https://github.com/codespell-project/codespell + rev: v2.2.6 + hooks: + - id: codespell - repo: local hooks: - id: check-executables