Skip to content

Commit

Permalink
use predefine action for formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
NikolaDucak committed Aug 23, 2023
1 parent eec51a1 commit b2f4190
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions .github/workflows/main-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
# they are grouped under the same job as it's simpler than cahing
# or artifact upload/download. Rith now the tests are pretty fast
# so not much would be gained from parallel run of test & analysis
build:
build-and-test:
runs-on: ubuntu-latest

steps:
Expand All @@ -36,7 +36,6 @@ jobs:
run: ctest -C ${{env.BUILD_TYPE}} --output-on-failure -E "LocalLogRepository"

- name: Static Analysis
if: always()
run: ln -s ./build/compile_commands.json && run-clang-tidy ./source/

code-formatting:
Expand All @@ -45,5 +44,8 @@ jobs:
steps:
- uses: actions/checkout@v3

- name: clang-format
run: find ./source ./test -iname '*.cpp' -o -iname '*.hpp' | xargs clang-format -n -Werror --ferror-limit=1
- uses: DoozyX/[email protected]
with:
source: 'source test'
extensions: 'hpp,cpp'
clangFormatVersion: 16

0 comments on commit b2f4190

Please sign in to comment.