From cd45c0242dae4d9172048778310679c7f063be7a Mon Sep 17 00:00:00 2001 From: bbhtt Date: Thu, 7 Nov 2024 10:15:13 +0530 Subject: [PATCH] ci: Make the check job run always --- .github/workflows/ci.yml | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a716dafa..7011f758 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -11,6 +11,7 @@ jobs: changes: runs-on: ubuntu-latest timeout-minutes: 60 + if: always() permissions: pull-requests: read outputs: @@ -49,20 +50,28 @@ jobs: check: runs-on: ubuntu-latest timeout-minutes: 60 + if: always() needs: changes - if: | - needs.changes.outputs.exceptions == 'false' && - needs.changes.outputs.exceptions == 'false' && - needs.changes.outputs.src-extra == 'false' && - needs.changes.outputs.docker == 'false' steps: - name: Check - run: echo "No filter matched. Perhaps this file is not covered by CI" && exit 1 + run: | + if ${{ + needs.changes.outputs.exceptions == 'false' && + needs.changes.outputs.src == 'false' && + needs.changes.outputs.src-extra == 'false' && + needs.changes.outputs.docker == 'false' + }}; then + echo "No filter matched. This file is not covered by CI" && exit 1 + else + echo "Found matching file" + fi exceptions: runs-on: ubuntu-latest timeout-minutes: 60 - needs: changes + needs: + - changes + - check if: ${{ needs.changes.outputs.exceptions == 'true' }} steps: - uses: actions/checkout@v4 @@ -77,7 +86,9 @@ jobs: ci: runs-on: ubuntu-latest timeout-minutes: 60 - needs: changes + needs: + - changes + - check if: ${{ needs.changes.outputs.src == 'true' || needs.changes.outputs.src-extra == 'true' }} steps: - uses: actions/checkout@v4 @@ -198,6 +209,7 @@ jobs: packages: write needs: - changes + - check - ci if: ${{ needs.changes.outputs.docker == 'true' && github.event_name != 'pull_request' && github.repository == 'flathub-infra/flatpak-builder-lint' && github.ref == 'refs/heads/master' }} uses: ./.github/workflows/docker.yml