Skip to content

Commit

Permalink
feat: add .clang-format spec
Browse files Browse the repository at this point in the history
  • Loading branch information
Tom94 committed Jan 27, 2025
1 parent 6a583d5 commit 7d94483
Showing 1 changed file with 61 additions and 0 deletions.
61 changes: 61 additions & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
AccessModifierOffset: -4
AlignAfterOpenBracket: BlockIndent
AlignArrayOfStructures: Left
AlignConsecutiveBitFields: Consecutive
AlignEscapedNewlines: Left
AlignOperands: false
AllowAllArgumentsOnNextLine: true
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortFunctionsOnASingleLine: true
AllowShortBlocksOnASingleLine: Always
AllowShortCaseLabelsOnASingleLine: true
AllowShortEnumsOnASingleLine: true
AllowShortLambdasOnASingleLine: true
AlwaysBreakBeforeMultilineStrings: true
AlwaysBreakTemplateDeclarations: MultiLine
BinPackArguments: false
BinPackParameters: false
BreakAfterAttributes: Leave
BreakBeforeBraces: Attach
BreakBeforeTernaryOperators: false
BreakConstructorInitializers: AfterColon
BreakInheritanceList: BeforeComma
BreakStringLiterals: false
ColumnLimit: 140
CompactNamespaces: true
ConstructorInitializerAllOnOneLineOrOnePerLine: true
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
EmptyLineAfterAccessModifier: Never
EmptyLineBeforeAccessModifier: Always
IncludeBlocks: Preserve
IndentCaseLabels: true
IndentPPDirectives: AfterHash
IndentWidth: 4
IndentWrappedFunctionNames: true
InsertBraces: true
InsertNewlineAtEOF: true
InsertTrailingCommas: Wrapped
MaxEmptyLinesToKeep: 1
PackConstructorInitializers: NextLine
PenaltyBreakAssignment: 65
PenaltyBreakBeforeFirstCallParameter: 16
PenaltyBreakComment: 320
PenaltyBreakFirstLessLess: 50
PenaltyBreakString: 0
PenaltyExcessCharacter: 10
PenaltyReturnTypeOnItsOwnLine: 100
PointerAlignment: Left
QualifierAlignment: Left
ReferenceAlignment: Left
SortIncludes: CaseSensitive
SpaceAfterCStyleCast: false
SpaceAfterLogicalNot: false
SpaceAfterTemplateKeyword: true
SpaceAroundPointerQualifiers: Both
SpaceBeforeParens: ControlStatementsExceptForEachMacros
SpacesInAngles: Never
TabWidth: 4
UseCRLF: false
UseTab: AlignWithSpaces

0 comments on commit 7d94483

Please sign in to comment.