Skip to content

Commit

Permalink
#132 Format using Google style
Browse files Browse the repository at this point in the history
  • Loading branch information
vityaman committed Jul 29, 2024
1 parent 71554ed commit 3ab090e
Show file tree
Hide file tree
Showing 10 changed files with 1,246 additions and 1,069 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,14 @@ jobs:
with:
create-symlink: true
key: ${{ github.job }}-${{ matrix.os }}
- name: Clang-Format
working-directory: ${{github.workspace}}/ports/cpp
run: |
( \
find source test -iname '*.hpp' -o -iname '*.cpp' \
| xargs clang-format -Werror --dry-run \
--fallback-style=Google --verbose \
)
- name: Configure
working-directory: ${{github.workspace}}/ports/cpp
run: |
Expand Down
13 changes: 13 additions & 0 deletions ports/cpp/.clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
Language: Cpp
BasedOnStyle: Google

AccessModifierOffset: -2

AllowShortFunctionsOnASingleLine: None
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false

DerivePointerAlignment: false
BreakConstructorInitializers: BeforeComma
AlignAfterOpenBracket: BlockIndent
Loading

0 comments on commit 3ab090e

Please sign in to comment.