forked from AliceO2Group/O2Physics
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.clang-format
More file actions
114 lines (114 loc) · 3.23 KB
/
.clang-format
File metadata and controls
114 lines (114 loc) · 3.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
BasedOnStyle: Google
AccessModifierOffset: -1
AlignEscapedNewlinesLeft: true
AlignTrailingComments: true
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortFunctionsOnASingleLine: true
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
#AlwaysBreakBeforeMultilineStrings: true
AlwaysBreakTemplateDeclarations: true
BinPackParameters: true
BreakBeforeBinaryOperators: false
BreakBeforeBraces: Linux
BreakBeforeTernaryOperators: true
BreakConstructorInitializersBeforeComma: false
ColumnLimit: 0
CommentPragmas: '^ IWYU pragma:'
ConstructorInitializerAllOnOneLineOrOnePerLine: true
ConstructorInitializerIndentWidth: 2
ContinuationIndentWidth: 2
Cpp11BracedListStyle: true
DerivePointerBinding: false
ExperimentalAutoDetectBinPacking: false
IndentCaseLabels: true
IndentFunctionDeclarationAfterType: true
IndentWidth: 2
InsertNewlineAtEOF: true
# It is broken on windows. Breaks all #include "header.h"
---
Language: Cpp
MaxEmptyLinesToKeep: 1
KeepEmptyLinesAtTheStartOfBlocks: true
NamespaceIndentation: None
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: false
PenaltyBreakBeforeFirstCallParameter: 1
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 200
SortIncludes: CaseSensitive
IncludeBlocks: Regroup
IncludeCategories:
# O2Physics, PWG
- Regex: ^(<|")PWG[A-Z]{2}/.*\.h
Priority: 2
CaseSensitive: true
# O2Physics, non-PWG
- Regex: ^(<|")(Common|ALICE3|DPG|EventFiltering|Tools|Tutorials)/.*\.h
Priority: 3
CaseSensitive: true
# O2
- Regex: ^(<|")(Algorithm|CCDB|Common[A-Z]|DataFormats|DCAFitter|Detectors|EMCAL|Field|Framework|FT0|FV0|GlobalTracking|GPU|ITS|MathUtils|MFT|MCH|MID|PHOS|PID|ReconstructionDataFormats|SimulationDataFormat|TOF|TPC|ZDC).*/.*\.h
Priority: 4
CaseSensitive: true
# ROOT
- Regex: ^(<|")(T[A-Z]|Math/|Roo[A-Z])[[:alnum:]/]+\.h
Priority: 5
CaseSensitive: true
# known third-party: KFParticle
- Regex: ^(<|")KF[A-Z][[:alnum:]]+\.h
Priority: 6
CaseSensitive: true
# known third-party: FastJet
- Regex: ^(<|")fastjet/
Priority: 6
CaseSensitive: true
# known third-party: ONNX runtime
- Regex: ^(<|")onnxruntime
Priority: 6
CaseSensitive: true
# incomplete path to DataModel
- Regex: ^(<|").*DataModel/
Priority: 1
CaseSensitive: true
# other third-party
- Regex: ^(<|")([[:alnum:]_]+/)+[[:alnum:]_]+\.h
Priority: 6
CaseSensitive: true
# other local-looking file
- Regex: ^".*\.
Priority: 1
CaseSensitive: true
# C system
- Regex: ^(<|")[[:lower:]_]+\.h(>|")
Priority: 102
CaseSensitive: true
# C++ system
- Regex: ^(<|")[[:lower:]_/]+(>|")
Priority: 101
CaseSensitive: true
# rest
- Regex: .*
Priority: 100
SpaceBeforeAssignmentOperators: true
SpaceBeforeParens: ControlStatements
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
SpacesInAngles: false
SpacesInContainerLiterals: true
SpacesInCStyleCastParentheses: false
SpacesInParentheses: false
Standard: Cpp11
TabWidth: 2
UseTab: Never
---
# Do not format protobuf files
Language: Proto
DisableFormat: true
---
Language: Json
# O2 dumps JSON files with 4-space indents.
IndentWidth: 4