From cc0418c55e7eb66457a2cd1ea3a0281c6c4cf845 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Carlos=20=C3=81lvaro?= Date: Sat, 6 Nov 2021 11:46:57 +0100 Subject: [PATCH] ci(debug): Fix if job level --- .github/workflows/publish.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 9efbe00..083b5a4 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -17,7 +17,6 @@ env: PLATFORMS: linux/amd64,linux/arm64,linux/arm/v7 CACHE_PATH: /tmp/.buildx-docker-salt-master-cache EXTRA_REGISTRIES: ghcr.io quay.io - DEBUG: true jobs: metadata: @@ -59,10 +58,10 @@ jobs: echo ::set-output name=created_on::${CREATED_ON} - name: Dump environment - if: ${{ env.DEBUG }} == 'true' + if: contains(toJSON(github.event.commits.*.message), 'ci(debug)') == true run: env | sort - name: Dump GitHub context - if: ${{ env.DEBUG }} == 'true' + if: contains(toJSON(github.event.commits.*.message), 'ci(debug)') == true env: GITHUB_CONTEXT: ${{ toJson(github) }} run: echo "${GITHUB_CONTEXT}" @@ -71,7 +70,7 @@ jobs: name: Publish runs-on: ubuntu-latest needs: metadata - if: ${{ env.DEBUG }} != 'false' + if: contains(toJSON(github.event.commits.*.message), 'ci(debug)') == false steps: - name: Checkout repository uses: actions/checkout@v2.4.0