Only test format when it is wanted
This commit is contained in:
parent
a6fcdec0f8
commit
6171c9d45d
4
.github/workflows/format.yml
vendored
4
.github/workflows/format.yml
vendored
|
@ -3,6 +3,10 @@ name: Code formatting
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
branches: [ master, develop ]
|
branches: [ master, develop ]
|
||||||
|
paths:
|
||||||
|
- '**.cpp'
|
||||||
|
- '**.h'
|
||||||
|
- '!src/libs/**'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
test-format:
|
test-format:
|
||||||
|
|
|
@ -16,6 +16,7 @@ for file in $CHANGED_FILES
|
||||||
do
|
do
|
||||||
[ -e "$file" ] || continue
|
[ -e "$file" ] || continue
|
||||||
case "$file" in
|
case "$file" in
|
||||||
|
src/libs/*) continue ;;
|
||||||
*.cpp|*.h)
|
*.cpp|*.h)
|
||||||
echo Checking "$file"
|
echo Checking "$file"
|
||||||
clang-format -i "$file"
|
clang-format -i "$file"
|
||||||
|
|
Loading…
Reference in New Issue
Block a user