Skip to content

Commit 3e305b9

Browse files
luk1337bgcngm
authored andcommitted
pre-commit: Enable clang-format
Change-Id: I7a22a5fe9ee7176604fed0825f96417c53adb1ff
1 parent 9525841 commit 3e305b9

2 files changed

Lines changed: 18 additions & 1 deletion

File tree

.clang-format

Lines changed: 0 additions & 1 deletion
This file was deleted.

.clang-format

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
BasedOnStyle: Google
2+
Standard: Cpp11
3+
AccessModifierOffset: -2
4+
AllowShortFunctionsOnASingleLine: Inline
5+
ColumnLimit: 100
6+
CommentPragmas: NOLINT:.*
7+
DerivePointerAlignment: false
8+
IncludeBlocks: Preserve
9+
IndentWidth: 4
10+
ContinuationIndentWidth: 8
11+
PointerAlignment: Left
12+
TabWidth: 4
13+
UseTab: Never

.pre-commit-config.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ repos:
88
- id: end-of-file-fixer
99
- id: check-yaml
1010
- id: check-added-large-files
11+
- repo: https://github.com/pre-commit/mirrors-clang-format
12+
rev: v21.1.8
13+
hooks:
14+
- id: clang-format
15+
types_or: [c, c++]
1116
- repo: https://github.com/macisamuele/language-formatters-pre-commit-hooks
1217
rev: v2.15.0
1318
hooks:

0 commit comments

Comments
 (0)