Run whatstyle to derive clang-format settings

find . -name "*.c" | xargs whatstyle --formatter clang-format
This commit is contained in:
Lassi Kortela 2019-08-09 13:24:52 +03:00
parent 32c77aefbc
commit 8c85386640
1 changed files with 20 additions and 0 deletions

20
.clang-format Normal file
View File

@ -0,0 +1,20 @@
---
BasedOnStyle: WebKit
AlignAfterOpenBracket: Align
AlignEscapedNewlines: DontAlign
AlignOperands: true
AlignTrailingComments: true
AllowShortBlocksOnASingleLine: true
AllowShortCaseLabelsOnASingleLine: true
AllowShortIfStatementsOnASingleLine: true
AllowShortLoopsOnASingleLine: true
BraceWrapping:
AfterFunction: true
BeforeElse: true
BreakBeforeBinaryOperators: None
BreakBeforeBraces: Custom
ContinuationIndentWidth: 0
DerivePointerAlignment: true
MaxEmptyLinesToKeep: 2
SortIncludes: false
SpacesBeforeTrailingComments: 2