From a12f795c09e6895c326d7d36c4dea9a263c5fd29 Mon Sep 17 00:00:00 2001 From: dczhang Date: Wed, 12 Oct 2022 21:08:31 +0800 Subject: [PATCH] add clang-format --- .clang-format | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 .clang-format diff --git a/.clang-format b/.clang-format new file mode 100644 index 0000000..b7c58b7 --- /dev/null +++ b/.clang-format @@ -0,0 +1,26 @@ +--- +Language: Cpp +BasedOnStyle: LLVM +AllowAllParametersOfDeclarationOnNextLine: false +AlwaysBreakTemplateDeclarations: true +BinPackArguments: false +BinPackParameters: false +BreakConstructorInitializers: BeforeComma +ColumnLimit: 120 +CommentPragmas: '^(!|NOLINT)' +ConstructorInitializerAllOnOneLineOrOnePerLine: true +IncludeBlocks: Regroup +IncludeCategories: + - Regex: '^<.*' + Priority: 2 + - Regex: '.*' + Priority: 1 +IndentCaseLabels: false +AllowShortCaseLabelsOnASingleLine: true +IndentWidth: 4 +KeepEmptyLinesAtTheStartOfBlocks: false +PenaltyReturnTypeOnItsOwnLine: 200 +SpacesBeforeTrailingComments: 1 +TabWidth: 4 +UseTab: Never +... -- GitLab