2022-02-25 01:44:39 +08:00
|
|
|
# See https://pre-commit.com for more information
|
|
|
|
# See https://pre-commit.com/hooks.html for more hooks
|
|
|
|
repos:
|
|
|
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
|
|
rev: v3.2.0
|
|
|
|
hooks:
|
|
|
|
- id: trailing-whitespace
|
|
|
|
|
|
|
|
- repo: local
|
|
|
|
hooks:
|
|
|
|
# Run astyle over the staged files with c and h extension found in the directories
|
|
|
|
# listed in the files regex pattern. Ignoring the files in the exclude pattern.
|
2023-12-04 04:18:34 +08:00
|
|
|
- id: format-source
|
|
|
|
name: Formatting source files
|
|
|
|
entry: astyle --options=scripts/code-format.cfg --ignore-exclude-errors
|
|
|
|
stages: [ commit ]
|
|
|
|
language: system
|
|
|
|
pass_filenames: true
|
|
|
|
verbose: true
|
|
|
|
files: |
|
|
|
|
(?x)^(
|
|
|
|
demos/ |
|
|
|
|
examples/ |
|
|
|
|
src/ |
|
|
|
|
tests/
|
|
|
|
)
|
|
|
|
exclude: |
|
|
|
|
(?x)^(
|
|
|
|
src/libs/ |
|
2024-04-20 19:14:25 +08:00
|
|
|
src/lv_conf_internal.h |
|
|
|
|
tests/test_images
|
2023-12-04 04:18:34 +08:00
|
|
|
)
|
|
|
|
types_or: ["c", "header"]
|
2023-10-24 01:57:04 +08:00
|
|
|
- repo: https://github.com/crate-ci/typos
|
|
|
|
rev: v1.16.20
|
|
|
|
hooks:
|
2023-12-04 04:18:34 +08:00
|
|
|
- id: typos
|
2023-11-09 18:37:33 +08:00
|
|
|
exclude: |
|
|
|
|
(?x)^(
|
|
|
|
src/libs/
|
|
|
|
)
|