mirror of
https://gitlab.com/mobian1/eg25-manager.git
synced 2025-08-28 23:03:24 +02:00
This will ensure our coding style is more clearly defined and allow contibutors to auto-format their code, bringing some more consistency.
49 lines
1.4 KiB
YAML
49 lines
1.4 KiB
YAML
BasedOnStyle: LLVM
|
|
|
|
ColumnLimit: 100
|
|
|
|
IndentWidth: 4
|
|
IndentGotoLabels: false
|
|
|
|
AlignArrayOfStructures: Left
|
|
AlignConsecutiveAssignments: None
|
|
AlignConsecutiveMacros: AcrossEmptyLines
|
|
AlignConsecutiveDeclarations:
|
|
Enabled: true
|
|
# Available only with clang-format 20+
|
|
# AlignFunctionDeclarations: true
|
|
AlignFunctionPointers: true
|
|
|
|
# Ensure we either have all args/params on a single line,
|
|
# or only one per line
|
|
BinPackArguments: false
|
|
BinPackParameters: false
|
|
# To be changed for clang-format 20+
|
|
# BinPackParameters: OnePerLine
|
|
|
|
# Avoid single-line enums/functions/ifs/loops/etc
|
|
AllowShortBlocksOnASingleLine: Never
|
|
AllowShortEnumsOnASingleLine: false
|
|
AllowShortFunctionsOnASingleLine: None
|
|
AllowShortCaseExpressionOnASingleLine: false
|
|
AllowShortCaseLabelsOnASingleLine: false
|
|
AllowShortIfStatementsOnASingleLine: Never
|
|
AllowShortLoopsOnASingleLine: false
|
|
|
|
BreakBeforeBinaryOperators: None
|
|
# Ensure function opening brackets are on their own line
|
|
BreakBeforeBraces: Linux
|
|
# Available only with clang-format 20+
|
|
# BreakBinaryOperations: OnePerLine
|
|
|
|
InsertNewlineAtEOF: true
|
|
|
|
# Don't be too strict on line lengths
|
|
PenaltyExcessCharacter: 10
|
|
# Prefer breaking arguments list over putting a function call
|
|
# on its own line after an assignment
|
|
PenaltyBreakAssignment: 200
|
|
PenaltyBreakBeforeFirstCallParameter: 200
|
|
# Ensure we never ever have the return type on a single line
|
|
PenaltyReturnTypeOnItsOwnLine: 1000
|