Merge pull request #1 from myrotvorets/renovate/vcpkg-digest #8
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: clang-tidy | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
workflow_dispatch: | |
permissions: | |
contents: read | |
jobs: | |
clang-tidy: | |
name: Run clang-tidy | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
steps: | |
- name: Check out the source code | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
with: | |
submodules: true | |
fetch-depth: 0 | |
- name: Install dependencies | |
uses: ./.github/actions/install-dependencies | |
- name: Set up vcpkg | |
uses: lukka/run-vcpkg@5e0cab206a5ea620130caf672fce3e4a6b5666a1 # v11.5 | |
- name: Configure | |
run: cmake -B build -DCMAKE_EXPORT_COMPILE_COMMANDS=ON | |
- name: Run clang-tidy | |
run: clang-tidy -p build $(jq -r 'map(select(.file | endswith(".cpp"))) | .[].file' build/compile_commands.json) --warnings-as-errors='*' |