Skip to content

Commit d8e7dbf

Browse files
wgtmacdongjoon-hyun
authored andcommitted
ORC-1835: [C++] Fix cpp-linter-action to build first
### What changes were proposed in this pull request? Insert a build step before cpp-linter-action to do its job. ### Why are the changes needed? We need to build C++ code to export command json file. ### How was this patch tested? Pass CI. ### Was this patch authored or co-authored using generative AI tooling? No. Closes #2113 from wgtmac/fix_cpp_linter. Authored-by: Gang Wu <ustcwg@gmail.com> Signed-off-by: Dongjoon Hyun <dongjoon@apache.org>
1 parent 3eb423a commit d8e7dbf

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

.github/workflows/build_and_test.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,11 @@ jobs:
179179
runs-on: ubuntu-24.04
180180
steps:
181181
- uses: actions/checkout@v4
182+
- name: Run build
183+
run: |
184+
mkdir build && cd build
185+
cmake .. -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DBUILD_JAVA=OFF
186+
cmake --build .
182187
- uses: cpp-linter/cpp-linter-action@v2.13.3
183188
id: linter
184189
continue-on-error: true
@@ -191,8 +196,7 @@ jobs:
191196
lines-changed-only: true
192197
thread-comments: true
193198
ignore: 'build|cmake_modules|conan|dev|docker|examples|java|site'
194-
database: build/compile_commands.json
195-
extra-args: #-Wno-unused-parameter
199+
database: build
196200
- name: Fail fast?!
197201
if: steps.linter.outputs.checks-failed != 0
198202
run: |

0 commit comments

Comments
 (0)