CodeCommitsIssuesPull requestsActionsInsightsSecurity
6eb949ca7825d74380a019dab13db6a8d6659814

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

.clang-format

87lines · modecode

1---
2BasedOnStyle: WebKit
3Language: Cpp
4AlignAfterOpenBracket: false
5BreakBeforeBraces: Allman
6BreakConstructorInitializersBeforeComma: false
7Cpp11BracedListStyle: false
8ColumnLimit: 140
9ConstructorInitializerAllOnOneLineOrOnePerLine: true
10ExperimentalAutoDetectBinPacking: true
11UseTab: Always
12Standard: Cpp11
13TabWidth: 4
14PointerAlignment: Middle
15MaxEmptyLinesToKeep: 2
16KeepEmptyLinesAtTheStartOfBlocks: false
17#AllowShortFunctionsOnASingleLine: Inline
18AllowShortFunctionsOnASingleLine: Empty
19AlwaysBreakTemplateDeclarations: true
20#SpaceAfterTemplateKeyword: true
21SortIncludes: true
22IncludeCategories:
23 - Regex: '^<[a-z_]+>'
24 Priority: 1
25 - Regex: '^<[a-z_]+.h>'
26 Priority: 2
27 - Regex: '^["<](common|ext|mysqlxx|daemon)/'
28 Priority: 90
29 - Regex: '^["<](DB)/'
30 Priority: 100
31 - Regex: '^["<](Poco)/'
32 Priority: 50
33 - Regex: '/'
34 Priority: 30
35 - Regex: '.*'
36 Priority: 40
37ReflowComments: false
38
39# Not changed:
40AccessModifierOffset: -4
41AlignConsecutiveAssignments: false
42AlignEscapedNewlinesLeft: false
43AlignOperands: false
44AlignTrailingComments: false
45AllowAllParametersOfDeclarationOnNextLine: true
46AllowShortBlocksOnASingleLine: false
47AllowShortCaseLabelsOnASingleLine: false
48AllowShortIfStatementsOnASingleLine: false
49AllowShortLoopsOnASingleLine: false
50AlwaysBreakAfterDefinitionReturnType: None
51AlwaysBreakBeforeMultilineStrings: false
52BinPackArguments: false
53BinPackParameters: false
54BreakBeforeBinaryOperators: All
55BreakBeforeTernaryOperators: true
56CommentPragmas: '^ IWYU pragma:'
57ConstructorInitializerIndentWidth: 4
58ContinuationIndentWidth: 4
59DerivePointerAlignment: false
60DisableFormat: false
61ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH ]
62IndentCaseLabels: false
63IndentWidth: 4
64IndentWrappedFunctionNames: false
65MacroBlockBegin: ''
66MacroBlockEnd: ''
67NamespaceIndentation: Inner
68ObjCBlockIndentWidth: 4
69ObjCSpaceAfterProperty: true
70ObjCSpaceBeforeProtocolList: true
71PenaltyBreakBeforeFirstCallParameter: 19
72PenaltyBreakComment: 300
73PenaltyBreakFirstLessLess: 120
74PenaltyBreakString: 1000
75PenaltyExcessCharacter: 1000000
76PenaltyReturnTypeOnItsOwnLine: 60
77SpaceAfterCStyleCast: false
78SpaceBeforeAssignmentOperators: true
79SpaceBeforeParens: ControlStatements
80SpaceInEmptyParentheses: false
81SpacesBeforeTrailingComments: 1
82SpacesInContainerLiterals: true
83SpacesInCStyleCastParentheses: false
84SpacesInParentheses: false
85SpacesInSquareBrackets: false
86...