Reuse built clang-tidy plugin across the shards #79100
Open
+120
−86
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Infrastructure "Reuse built clang-tidy plugin across github action shards"
Purpose of change
This is a followup to #78801 (#78801 (comment))
It is a bit silly to re-build and re-test our clang tidy plugin thrice for each workflow run when we can do it only once instead. This PR does so.
Describe the solution
At a high level: split our matrixed clang-tidy job in two
This resulted in a split of
./build-scripts/clang-tidy.sh
into two scripts (one for build, and one for run) because keeping it all in one file was getting cumbersome.This also led to quite a bit of pruning of what seems to be legacy code in the script and the workflow, which was used for active development of the plugin back in the day. But in the current state (even without this PR) I find it hard to believe that anyone actually runs
./build-scripts/clang-tidy.sh
for local development given the amount of effort needed to do so (and the sparse anecdotal experience of people in discord).As a drive-by change, I bumped the github runner to ubuntu-24.04 which allowed me to stop adding custom llvm apt repo for clang-17, and instead reuse the stock ubuntu one (since ubuntu-24.04 has clang-17 in stock)
Describe alternatives you've considered
Testing
Seems to work in my local fork moxian#4
Let's see if it also works in this upstream CI
Additional context