From c6b02adc982382044c86fa11dcaf012fbe78715e Mon Sep 17 00:00:00 2001 From: Jim Huang Date: Mon, 18 Sep 2023 11:30:54 +0800 Subject: [PATCH] CI: Only perform extensive checks on source file changes --- .github/workflows/status-check.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/status-check.yaml b/.github/workflows/status-check.yaml index 49c2d04..8789ba2 100644 --- a/.github/workflows/status-check.yaml +++ b/.github/workflows/status-check.yaml @@ -14,7 +14,14 @@ jobs: steps: - name: checkout code uses: actions/checkout@v4 + - name: Test changed source files + id: changed-files + uses: tj-actions/changed-files@v39 + with: + files: examples/** - name: validate coding style and functionality + if: ${{ steps.changed-files.outputs.any_changed == 'true' || + github.event_name == 'workflow_dispatch' }} run: | sudo apt-get install -q -y clang-format-12 sudo apt-get install -q -y cppcheck