Skip to content

Commit e4d9487

Browse files
authored
Update formatting-check.yml
Signed-off-by: Will <2185386+willhoy@users.noreply.github.com>
1 parent 2050eaf commit e4d9487

File tree

1 file changed

+9
-19
lines changed

1 file changed

+9
-19
lines changed
Lines changed: 9 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,13 @@
1-
name: Formatting check
2-
3-
on:
4-
pull_request:
5-
types:
6-
- "opened"
7-
- "reopened"
8-
- "synchronize"
9-
- "labeled"
10-
- "unlabeled"
11-
1+
name: clang-format Check
2+
on: [push, pull_request]
123
jobs:
13-
formatting_check:
4+
formatting-check:
145
name: Formatting Check
156
runs-on: ubuntu-latest
167
steps:
17-
- uses: actions/checkout@v4
18-
with:
19-
fetch-depth: 0
20-
- name: clang-format style check
21-
run: |
22-
git clang-format-14 --diff -q origin/main | tee format_diff.txt
23-
if [ -s format_diff.txt ]; then exit 1; fi
8+
- uses: actions/checkout@v4
9+
- name: Run clang-format style check for C++ programs.
10+
uses: jidicula/clang-format-action@v4.15.0
11+
with:
12+
clang-format-version: '14'
13+
check-path: 'src'

0 commit comments

Comments
 (0)