Repository navigation
Fix #15211 --cppcheck-build-dir: summaries are written to a file that is never read (with -D or dots in the file name) #19524
Workflow file for this run
This file contains hidden or 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
| # Syntax reference https://help.github.com/en/actions/reference/workflow-syntax-for-github-actions | |
| # Environment reference https://help.github.com/en/actions/reference/virtual-environments-for-github-hosted-runners | |
| name: format | |
| on: | |
| push: | |
| branches: | |
| - 'main' | |
| - 'releases/**' | |
| - '2.*' | |
| tags: | |
| - '2.*' | |
| pull_request: | |
| permissions: | |
| contents: read | |
| jobs: | |
| build: | |
| runs-on: ubuntu-22.04 | |
| env: | |
| UNCRUSTIFY_VERSION: 0.80.1 | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| persist-credentials: false | |
| - name: Cache uncrustify | |
| uses: actions/cache@v5 | |
| id: cache-uncrustify | |
| with: | |
| path: | | |
| ~/uncrustify | |
| key: ${{ runner.os }}-uncrustify-${{ env.UNCRUSTIFY_VERSION }} | |
| - name: build uncrustify | |
| if: steps.cache-uncrustify.outputs.cache-hit != 'true' | |
| run: | | |
| set -x | |
| wget https://github.com/uncrustify/uncrustify/archive/refs/tags/uncrustify-${{ env.UNCRUSTIFY_VERSION }}.tar.gz | |
| tar xzvf uncrustify-${{ env.UNCRUSTIFY_VERSION }}.tar.gz | |
| cd uncrustify-uncrustify-${{ env.UNCRUSTIFY_VERSION }} | |
| cmake -S . -B build -DCMAKE_BUILD_TYPE=Release | |
| cmake --build build -- -j$(nproc) -s | |
| mkdir ~/uncrustify | |
| cp build/uncrustify ~/uncrustify/ | |
| - name: Uncrustify check | |
| run: | | |
| UNCRUSTIFY=~/uncrustify/uncrustify ./runformat | |
| git diff | |
| git diff | diff - /dev/null &> /dev/null |