diff --git a/.clang-format b/.clang-format new file mode 100644 index 0000000..97e9d15 --- /dev/null +++ b/.clang-format @@ -0,0 +1,47 @@ +BasedOnStyle: LLVM +--- +Language: Cpp +AlignAfterOpenBracket: DontAlign +AlignOperands: AlignAfterOperator +AllowShortCaseLabelsOnASingleLine: true +AllowShortIfStatementsOnASingleLine: WithoutElse +AllowShortLoopsOnASingleLine: true +AccessModifierOffset: -4 +AlwaysBreakTemplateDeclarations: Yes +BraceWrapping: + SplitEmptyFunction: false + SplitEmptyRecord: false + SplitEmptyNamespace: false +#BracedInitializerIndentWidth: 4 +BreakBeforeBinaryOperators: NonAssignment +BreakConstructorInitializers: BeforeComma +BreakInheritanceList: BeforeComma +ConstructorInitializerIndentWidth: 8 +ContinuationIndentWidth: 8 +IncludeBlocks: Regroup +IncludeCategories: + - Regex: '^"parselink/' + Priority: 1 + SortPriority: 1 + CaseSensitive: false + - Regex: '^<(fmt|tl|magic_enum|ut)/' + Priority: 2 + SortPriority: 2 + CaseSensitive: false + - Regex: '.*' + Priority: 1 + SortPriority: 0 +IncludeIsMainRegex: '(_test)?$' +IndentAccessModifiers: false +IndentCaseLabels: true +IndentGotoLabels: false +IndentWidth: 4 +InsertNewlineAtEOF: true +#KeepEmptyLinesAtEOF: true +KeepEmptyLinesAtTheStartOfBlocks: false +PointerAlignment: Left +QualifierAlignment: Right +#QualifierOrder: ['inline', 'static', 'constexpr', 'const', 'volatile'] +ReferenceAlignment: Pointer +SeparateDefinitionBlocks: Always +---