This commit is contained in:
louiscklaw
2025-01-31 19:24:01 +08:00
parent 1d3678b2fb
commit 4afadb4bfd
54 changed files with 2604 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
fail_fast: false
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- repo: https://gitlab.com/daverona/pre-commit-cpp
rev: 0.8.0 # use the most recent version
hooks:
- id: clang-format # formatter of C/C++ code based on a style guide: LLVM, Google, Chromium, Mozilla, and WebKit available
args: ["-style=Google"]
- id: cpplint # linter (or style-error checker) for Google C++ Style Guide
- id: cppcheck # static analyzer of C/C++ code
- repo: https://github.com/psf/black
rev: 22.3.0
hooks:
- id: black
args: ["--line-length", "79"]