c++ code format (#4527)

This commit is contained in:
zhupengyang
2025-10-22 17:59:50 +08:00
committed by GitHub
parent d7bcedf421
commit 3a6883ac1a
97 changed files with 8760 additions and 7382 deletions

View File

@@ -1,3 +1,7 @@
exclude: |
(?x)^(
dockerfiles/.+
)$
default_install_hook_types:
- pre-commit
- commit-msg
@@ -27,6 +31,15 @@ repos:
hooks:
- id: ruff
args: [--output-format, github, --fix, --line-length=120, --config, pyproject.toml]
# For C++ files
- repo: local
hooks:
- id: clang-format
name: clang-format
description: Format files with ClangFormat.
entry: clang-format -i
language: system
files: \.(c|cc|cxx|cpp|cu|h|cuh|hpp|hxx|xpu|kps)$
# # 拼写检查
# - repo: https://github.com/codespell-project/codespell
# rev: v2.4.1