[Github] Make PR formatting job only run with C/C++ changes (#69556)
Currently the PR formatting job only runs clang-format. There isn't a lot of utility in running it if there aren't any C/C++ changes as there will be nothing to format. This isn't super noisy currently as the job doesn't fail if there aren't any C/C++ changes, but it's a bit of a waste. In addition, this patch names the code formatting job "Check C++ Formatting" to make it clear that this job only checks C/C++ formatting rather than Python formatting/other languages.
This commit is contained in:
parent
1be3b1ef51
commit
80b2aac2c6
13
.github/workflows/pr-code-format.yml
vendored
13
.github/workflows/pr-code-format.yml
vendored
@ -1,10 +1,19 @@
|
||||
name: "Check code formatting"
|
||||
on: pull_request_target
|
||||
|
||||
on:
|
||||
pull_request_target:
|
||||
paths:
|
||||
- '**/*.cpp'
|
||||
- '**/*.c'
|
||||
- '**/*.h'
|
||||
- '**/*.inc'
|
||||
|
||||
permissions:
|
||||
pull-requests: write
|
||||
|
||||
jobs:
|
||||
code_formatter:
|
||||
cpp_code_formatter:
|
||||
name: "Check C++ Formatting"
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Fetch LLVM sources
|
||||
|
Loading…
x
Reference in New Issue
Block a user