Skip to content

Commit a38fdae

Browse files
authored
Merge pull request #6 from ElectronicCats/test_ci
Clang Format for flipper with pre commit
2 parents 98feb30 + 131707e commit a38fdae

16 files changed

+2026
-1852
lines changed

.clang-format

+244-15
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,245 @@
11
---
2-
# options: https://clang.llvm.org/docs/ClangFormatStyleOptions.html
3-
BasedOnStyle: chromium
4-
IndentWidth: 2
5-
# Must be 80 characters or less!
6-
# ColumnLimit: 80
7-
# does (int) x instead of (int)x
8-
SpaceAfterCStyleCast: true
9-
# spaces, not tabs!
10-
UseTab: Never
11-
#
12-
AlignTrailingComments: true
13-
# #define SHORT_NAME 42
14-
# #define LONGER_NAME 0x007f # does nice spacing for macros
15-
AlignConsecutiveMacros: Consecutive
16-
IndentPPDirectives: BeforeHash
2+
Language: Cpp
3+
AccessModifierOffset: -4
4+
AlignAfterOpenBracket: AlwaysBreak
5+
AlignArrayOfStructures: None
6+
AlignConsecutiveAssignments:
7+
Enabled: false
8+
AcrossEmptyLines: false
9+
AcrossComments: false
10+
AlignCompound: false
11+
AlignFunctionPointers: false
12+
PadOperators: true
13+
AlignConsecutiveBitFields:
14+
Enabled: true
15+
AcrossEmptyLines: true
16+
AcrossComments: true
17+
AlignCompound: false
18+
AlignFunctionPointers: false
19+
PadOperators: true
20+
AlignConsecutiveDeclarations:
21+
Enabled: false
22+
AcrossEmptyLines: false
23+
AcrossComments: false
24+
AlignCompound: false
25+
AlignFunctionPointers: false
26+
PadOperators: true
27+
AlignConsecutiveMacros:
28+
Enabled: true
29+
AcrossEmptyLines: false
30+
AcrossComments: true
31+
AlignCompound: true
32+
AlignFunctionPointers: false
33+
PadOperators: true
34+
AlignConsecutiveShortCaseStatements:
35+
Enabled: false
36+
AcrossEmptyLines: false
37+
AcrossComments: false
38+
AlignCaseColons: false
39+
AlignEscapedNewlines: Left
40+
AlignOperands: Align
41+
AlignTrailingComments:
42+
Kind: Never
43+
OverEmptyLines: 0
44+
AllowAllArgumentsOnNextLine: true
45+
AllowAllParametersOfDeclarationOnNextLine: false
46+
AllowBreakBeforeNoexceptSpecifier: Never
47+
AllowShortBlocksOnASingleLine: Never
48+
AllowShortCaseLabelsOnASingleLine: false
49+
AllowShortCompoundRequirementOnASingleLine: true
50+
AllowShortEnumsOnASingleLine: false
51+
AllowShortFunctionsOnASingleLine: None
52+
AllowShortIfStatementsOnASingleLine: WithoutElse
53+
AllowShortLambdasOnASingleLine: All
54+
AllowShortLoopsOnASingleLine: false
55+
AlwaysBreakAfterDefinitionReturnType: None
56+
AlwaysBreakAfterReturnType: None
57+
AlwaysBreakBeforeMultilineStrings: false
58+
AlwaysBreakTemplateDeclarations: Yes
59+
AttributeMacros:
60+
- __capability
61+
BinPackArguments: false
62+
BinPackParameters: false
63+
BitFieldColonSpacing: Both
64+
BraceWrapping:
65+
AfterCaseLabel: false
66+
AfterClass: false
67+
AfterControlStatement: Never
68+
AfterEnum: false
69+
AfterExternBlock: false
70+
AfterFunction: false
71+
AfterNamespace: false
72+
AfterObjCDeclaration: false
73+
AfterStruct: false
74+
AfterUnion: false
75+
BeforeCatch: false
76+
BeforeElse: false
77+
BeforeLambdaBody: false
78+
BeforeWhile: false
79+
IndentBraces: false
80+
SplitEmptyFunction: true
81+
SplitEmptyRecord: true
82+
SplitEmptyNamespace: true
83+
BreakAdjacentStringLiterals: true
84+
BreakAfterAttributes: Leave
85+
BreakAfterJavaFieldAnnotations: false
86+
BreakArrays: true
87+
BreakBeforeBinaryOperators: None
88+
BreakBeforeConceptDeclarations: Always
89+
BreakBeforeBraces: Attach
90+
BreakBeforeInlineASMColon: OnlyMultiline
91+
BreakBeforeTernaryOperators: false
92+
BreakConstructorInitializers: BeforeComma
93+
BreakInheritanceList: BeforeColon
94+
BreakStringLiterals: false
95+
ColumnLimit: 99
96+
CommentPragmas: '^ IWYU pragma:'
97+
CompactNamespaces: false
98+
ConstructorInitializerIndentWidth: 4
99+
ContinuationIndentWidth: 4
100+
Cpp11BracedListStyle: true
101+
DerivePointerAlignment: false
102+
DisableFormat: false
103+
EmptyLineAfterAccessModifier: Never
104+
EmptyLineBeforeAccessModifier: LogicalBlock
105+
ExperimentalAutoDetectBinPacking: false
106+
FixNamespaceComments: false
107+
ForEachMacros:
108+
- foreach
109+
- Q_FOREACH
110+
- BOOST_FOREACH
111+
- M_EACH
112+
IfMacros:
113+
- KJ_IF_MAYBE
114+
IncludeBlocks: Preserve
115+
IncludeCategories:
116+
- Regex: '.*'
117+
Priority: 1
118+
SortPriority: 0
119+
CaseSensitive: false
120+
- Regex: '^(<|"(gtest|gmock|isl|json)/)'
121+
Priority: 3
122+
SortPriority: 0
123+
CaseSensitive: false
124+
- Regex: '.*'
125+
Priority: 1
126+
SortPriority: 0
127+
CaseSensitive: false
128+
IncludeIsMainRegex: '(Test)?$'
129+
IncludeIsMainSourceRegex: ''
130+
IndentAccessModifiers: false
131+
IndentCaseBlocks: false
132+
IndentCaseLabels: false
133+
IndentExternBlock: AfterExternBlock
134+
IndentGotoLabels: true
135+
IndentPPDirectives: None
136+
IndentRequiresClause: false
137+
IndentWidth: 4
138+
IndentWrappedFunctionNames: true
139+
InsertBraces: false
140+
InsertNewlineAtEOF: true
141+
InsertTrailingCommas: None
142+
IntegerLiteralSeparator:
143+
Binary: 0
144+
BinaryMinDigits: 0
145+
Decimal: 0
146+
DecimalMinDigits: 0
147+
Hex: 0
148+
HexMinDigits: 0
149+
JavaScriptQuotes: Leave
150+
JavaScriptWrapImports: true
151+
KeepEmptyLinesAtTheStartOfBlocks: false
152+
KeepEmptyLinesAtEOF: false
153+
LambdaBodyIndentation: Signature
154+
LineEnding: DeriveLF
155+
MacroBlockBegin: ''
156+
MacroBlockEnd: ''
157+
MaxEmptyLinesToKeep: 1
158+
NamespaceIndentation: None
159+
ObjCBinPackProtocolList: Auto
160+
ObjCBlockIndentWidth: 4
161+
ObjCBreakBeforeNestedBlockParam: true
162+
ObjCSpaceAfterProperty: true
163+
ObjCSpaceBeforeProtocolList: true
164+
PackConstructorInitializers: BinPack
165+
PenaltyBreakAssignment: 10
166+
PenaltyBreakBeforeFirstCallParameter: 30
167+
PenaltyBreakComment: 10
168+
PenaltyBreakFirstLessLess: 0
169+
PenaltyBreakOpenParenthesis: 0
170+
PenaltyBreakScopeResolution: 500
171+
PenaltyBreakString: 10
172+
PenaltyBreakTemplateDeclaration: 10
173+
PenaltyExcessCharacter: 100
174+
PenaltyIndentedWhitespace: 0
175+
PenaltyReturnTypeOnItsOwnLine: 60
176+
PointerAlignment: Left
177+
PPIndentWidth: -1
178+
QualifierAlignment: Leave
179+
ReferenceAlignment: Pointer
180+
ReflowComments: false
181+
RemoveBracesLLVM: false
182+
RemoveParentheses: Leave
183+
RemoveSemicolon: true
184+
RequiresClausePosition: OwnLine
185+
RequiresExpressionIndentation: OuterScope
186+
SeparateDefinitionBlocks: Leave
187+
ShortNamespaceLines: 1
188+
SkipMacroDefinitionBody: false
189+
SortIncludes: Never
190+
SortJavaStaticImport: Before
191+
SortUsingDeclarations: Never
192+
SpaceAfterCStyleCast: false
193+
SpaceAfterLogicalNot: false
194+
SpaceAfterTemplateKeyword: true
195+
SpaceAroundPointerQualifiers: Default
196+
SpaceBeforeAssignmentOperators: true
197+
SpaceBeforeCaseColon: false
198+
SpaceBeforeCpp11BracedList: false
199+
SpaceBeforeCtorInitializerColon: true
200+
SpaceBeforeInheritanceColon: true
201+
SpaceBeforeJsonColon: false
202+
SpaceBeforeParens: Never
203+
SpaceBeforeParensOptions:
204+
AfterControlStatements: false
205+
AfterForeachMacros: false
206+
AfterFunctionDefinitionName: false
207+
AfterFunctionDeclarationName: false
208+
AfterIfMacros: false
209+
AfterOverloadedOperator: false
210+
AfterPlacementOperator: true
211+
AfterRequiresInClause: false
212+
AfterRequiresInExpression: false
213+
BeforeNonEmptyParentheses: false
214+
SpaceBeforeRangeBasedForLoopColon: true
215+
SpaceBeforeSquareBrackets: false
216+
SpaceInEmptyBlock: false
217+
SpacesBeforeTrailingComments: 1
218+
SpacesInAngles: Never
219+
SpacesInContainerLiterals: false
220+
SpacesInLineCommentPrefix:
221+
Minimum: 1
222+
Maximum: -1
223+
SpacesInParens: Never
224+
SpacesInParensOptions:
225+
InCStyleCasts: false
226+
InConditionalStatements: false
227+
InEmptyParentheses: false
228+
Other: false
229+
SpacesInSquareBrackets: false
230+
Standard: c++20
231+
StatementAttributeLikeMacros:
232+
- Q_EMIT
233+
StatementMacros:
234+
- Q_UNUSED
235+
- QT_REQUIRE_VERSION
236+
TabWidth: 4
237+
UseTab: Never
238+
VerilogBreakBetweenInstancePorts: true
239+
WhitespaceSensitiveMacros:
240+
- STRINGIZE
241+
- PP_STRINGIZE
242+
- BOOST_PP_STRINGIZE
243+
- NS_SWIFT_NAME
244+
- CF_SWIFT_NAME
245+
...

0 commit comments

Comments
 (0)