summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal@nekernel.org>2025-12-05 08:56:49 -0500
committerAmlal El Mahrouss <amlal@nekernel.org>2025-12-05 08:56:49 -0500
commit217d937e2d661ceb346ac02a53b436afbc302592 (patch)
tree18704a79db515eaa3bb68196f1e0cde4ac42358e
parentbf9143960a12d3b80309ec6949ea797f591e2eb1 (diff)
chore: add clang-format, and editorconfig.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
-rw-r--r--.clang-format29
-rw-r--r--.editorconfig16
2 files changed, 45 insertions, 0 deletions
diff --git a/.clang-format b/.clang-format
new file mode 100644
index 0000000..3943f55
--- /dev/null
+++ b/.clang-format
@@ -0,0 +1,29 @@
+BasedOnStyle: Google
+IndentWidth: 2
+TabWidth: 2
+UseTab: Never
+ColumnLimit: 100
+DerivePointerAlignment: false
+PointerAlignment: Left
+AllowShortFunctionsOnASingleLine: Inline
+AllowShortIfStatementsOnASingleLine: true
+AllowShortLoopsOnASingleLine: true
+SortIncludes: true
+IncludeBlocks: Preserve
+SpaceAfterCStyleCast: true
+SpaceBeforeParens: ControlStatements
+SpacesInAngles: false
+SpacesInContainerLiterals: true
+SpacesInParentheses: false
+SpacesInSquareBrackets: false
+BreakBeforeBraces: Attach
+ConstructorInitializerAllOnOneLineOrOnePerLine: true
+Cpp11BracedListStyle: true
+NamespaceIndentation: Inner
+ReflowComments: true
+AlignConsecutiveAssignments: true
+AlignConsecutiveDeclarations: true
+AlignTrailingComments: true
+FixNamespaceComments: true
+IncludeIsMainRegex: '(Test)?$'
+SortUsingDeclarations: true
diff --git a/.editorconfig b/.editorconfig
new file mode 100644
index 0000000..ef6cea0
--- /dev/null
+++ b/.editorconfig
@@ -0,0 +1,16 @@
+root = true
+
+[*.{cpp,hpp}]
+indent_size = 4
+tab_width = 4
+indent_style = space
+
+[*.{pro,pri}]
+indent_size = 4
+tab_width = 4
+indent_style = space
+
+[*.{md,markdown}]
+indent_size = 2
+tab_width = 2
+indent_style = space