Add clang-format rules
This commit is contained in:
50
.clang-format
Normal file
50
.clang-format
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
---
|
||||||
|
BasedOnStyle: WebKit
|
||||||
|
AccessModifierOffset: "-4"
|
||||||
|
AlignAfterOpenBracket: Align
|
||||||
|
AlignEscapedNewlines: Left
|
||||||
|
AlignOperands: true
|
||||||
|
AllowShortBlocksOnASingleLine: Always
|
||||||
|
AllowShortCaseLabelsOnASingleLine: true
|
||||||
|
AllowShortIfStatementsOnASingleLine: AllIfsAndElse
|
||||||
|
AllowShortLoopsOnASingleLine: true
|
||||||
|
BreakBeforeBinaryOperators: NonAssignment
|
||||||
|
BreakBeforeBraces: Allman
|
||||||
|
BreakBeforeTernaryOperators: false
|
||||||
|
BreakInheritanceList: BeforeComma
|
||||||
|
BreakStringLiterals: false
|
||||||
|
ColumnLimit: "120"
|
||||||
|
CommentPragmas: .*
|
||||||
|
ContinuationIndentWidth: "0"
|
||||||
|
DerivePointerAlignment: true
|
||||||
|
EmptyLineBeforeAccessModifier: Always
|
||||||
|
IncludeBlocks: Merge
|
||||||
|
IndentCaseLabels: true
|
||||||
|
IndentPPDirectives: BeforeHash
|
||||||
|
IndentWidth: "4"
|
||||||
|
IndentWrappedFunctionNames: true
|
||||||
|
KeepEmptyLinesAtEOF: true
|
||||||
|
KeepEmptyLinesAtTheStartOfBlocks: false
|
||||||
|
MaxEmptyLinesToKeep: "2"
|
||||||
|
NamespaceIndentation: All
|
||||||
|
ObjCSpaceAfterProperty: false
|
||||||
|
ObjCSpaceBeforeProtocolList: false
|
||||||
|
PackConstructorInitializers: NextLine
|
||||||
|
PenaltyBreakAssignment: 20
|
||||||
|
ReflowComments: false
|
||||||
|
SortIncludes: Never
|
||||||
|
SortUsingDeclarations: Never
|
||||||
|
SpaceAfterCStyleCast: true
|
||||||
|
SpaceAfterTemplateKeyword: false
|
||||||
|
SpaceBeforeRangeBasedForLoopColon: false
|
||||||
|
SpaceInEmptyBlock: false
|
||||||
|
SpacesInAngles: false
|
||||||
|
SpacesInContainerLiterals: false
|
||||||
|
Standard: Cpp11
|
||||||
|
TabWidth: "4"
|
||||||
|
UseTab: ForIndentation
|
||||||
|
AllowAllConstructorInitializersOnNextLine: true
|
||||||
|
ConstructorInitializerAllOnOneLineOrOnePerLine: false
|
||||||
|
SpaceInEmptyParentheses: false
|
||||||
|
SpacesInCStyleCastParentheses: false
|
||||||
|
SpacesInParentheses: false
|
||||||
Reference in New Issue
Block a user