ci: Prevent running check, docs and test suites on tags

This doesn't make sense, because each tag is only pushed when those
pipelines have already passed. Thus, we can save time and avoid wasting
resources and don't run those again.
This commit is contained in:
Wolfgang Walther
2024-05-12 15:01:20 +02:00
parent 4a3fdc175c
commit 5c040e74f5
+3 -2
View File
@@ -18,6 +18,7 @@ concurrency:
jobs: jobs:
check: check:
name: Check name: Check
if: startsWith(github.ref, 'refs/heads/')
uses: ./.github/workflows/check.yaml uses: ./.github/workflows/check.yaml
secrets: secrets:
CACHIX_AUTH_TOKEN: ${{ secrets.CACHIX_AUTH_TOKEN }} CACHIX_AUTH_TOKEN: ${{ secrets.CACHIX_AUTH_TOKEN }}
@@ -25,6 +26,7 @@ jobs:
docs: docs:
name: Docs name: Docs
if: startsWith(github.ref, 'refs/heads/')
uses: ./.github/workflows/docs.yaml uses: ./.github/workflows/docs.yaml
secrets: secrets:
CACHIX_AUTH_TOKEN: ${{ secrets.CACHIX_AUTH_TOKEN }} CACHIX_AUTH_TOKEN: ${{ secrets.CACHIX_AUTH_TOKEN }}
@@ -32,6 +34,7 @@ jobs:
test: test:
name: Test name: Test
if: startsWith(github.ref, 'refs/heads/')
uses: ./.github/workflows/test.yaml uses: ./.github/workflows/test.yaml
secrets: secrets:
CACHIX_AUTH_TOKEN: ${{ secrets.CACHIX_AUTH_TOKEN }} CACHIX_AUTH_TOKEN: ${{ secrets.CACHIX_AUTH_TOKEN }}
@@ -147,8 +150,6 @@ jobs:
name: Release / Prepare name: Release / Prepare
if: | if: |
startsWith(github.ref, 'refs/tags/') && startsWith(github.ref, 'refs/tags/') &&
needs.docs.result == 'success' &&
needs.test.result == 'success' &&
needs.build.result == 'success' && needs.build.result == 'success' &&
(needs.arm.result == 'skipped' || success()) (needs.arm.result == 'skipped' || success())
runs-on: ubuntu-22.04 runs-on: ubuntu-22.04