-
-
Notifications
You must be signed in to change notification settings - Fork 264
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use latest clang format action (#4807)
- Loading branch information
Showing
2 changed files
with
10 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,20 @@ | ||
name: clang-format Check | ||
on: | ||
pull_request: | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
formatting-check: | ||
name: Formatting Check | ||
runs-on: ubuntu-latest | ||
if: "!contains(github.event.head_commit.message, 'skip-ci')" | ||
steps: | ||
- uses: actions/[email protected] | ||
|
||
- name: Run clang-format style check for C and Java code | ||
uses: DoozyX/[email protected] | ||
uses: DoozyX/[email protected].2 | ||
with: | ||
source: '.' | ||
extensions: 'c,h,cpp,hpp,java' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,8 +11,10 @@ name: clang-format Commit Changes | |
on: | ||
workflow_dispatch: | ||
push: | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
formatting-check: | ||
name: Commit Format Changes | ||
|
@@ -21,16 +23,18 @@ jobs: | |
permissions: | ||
contents: write # In order to allow EndBug/add-and-commit to commit changes | ||
steps: | ||
- uses: actions/checkout@9a9194f87191a7e9055e3e9b95b8cfb13023bb08 # v4.1.7 | ||
- uses: actions/[email protected] | ||
|
||
- name: Fix C and Java formatting issues detected by clang-format | ||
uses: DoozyX/clang-format-lint-action@caa179272c6ee7f1d25dfb503ee0c410c26ebd98 # v0.13 | ||
uses: DoozyX/clang-format-lint-action@v0.18.2 | ||
with: | ||
source: '.' | ||
extensions: 'c,h,cpp,hpp,java' | ||
clangFormatVersion: 13 | ||
inplace: True | ||
style: file | ||
exclude: './config ./hl/src/H5LTanalyze.c ./hl/src/H5LTparse.c ./hl/src/H5LTparse.h ./src/H5Epubgen.h ./src/H5Einit.h ./src/H5Eterm.h ./src/H5Edefin.h ./src/H5version.h ./src/H5overflow.h' | ||
|
||
- uses: EndBug/add-and-commit@a94899bca583c204427a224a7af87c02f9b325d5 # v9.1.4 | ||
with: | ||
author_name: github-actions | ||
|