Update clang-format.

This commit is contained in:
Jean-Philip Desjardins 2023-08-18 10:33:11 -04:00
parent 907442608a
commit a73b97f0be
2 changed files with 26 additions and 4 deletions

View file

@ -1,7 +1,26 @@
# Settings tested with clang-format 16
AccessModifierOffset: -4
AllowShortBlocksOnASingleLine: Always
AllowShortFunctionsOnASingleLine: None
AllowShortIfStatementsOnASingleLine: true
BreakBeforeBraces: Allman
BreakBeforeBraces: Custom
BraceWrapping:
AfterEnum: true
AfterClass: true
AfterCaseLabel: true
AfterStruct: true
AfterUnion: true
AfterExternBlock: true
AfterObjCDeclaration: true
AfterFunction: true
AfterNamespace: true
AfterControlStatement: Always
BeforeCatch: true
BeforeElse: true
BeforeWhile: false
SplitEmptyFunction: true
BeforeLambdaBody: false
BreakConstructorInitializers: BeforeComma
ColumnLimit: 0
FixNamespaceComments: false
@ -10,6 +29,9 @@ NamespaceIndentation: All
PointerBindsToType: true
SortIncludes: false
SpaceBeforeParens: Never
Standard: Cpp11
Standard: c++17
SpacesInLineCommentPrefix:
Minimum: 0
Maximum: -1
TabWidth: 4
UseTab: ForIndentation

View file

@ -6,12 +6,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: DoozyX/clang-format-lint-action@v0.11
- uses: DoozyX/clang-format-lint-action@v0.16.2
with:
source: './Source ./tools'
exclude: './Source/ui_qt/win32/Resources ./Source/ui_libretro/ext'
extensions: 'h,cpp,c,m,mm'
clangFormatVersion: 6
clangFormatVersion: 16
inplace: True
- name: Check for changes
run: |