From b3645b33dde9f7a786dbc84df1f3ce15c60b268a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adri=C3=A0=20Casaj=C3=BAs?= Date: Wed, 11 May 2022 16:48:27 +0200 Subject: [PATCH] Set global change for the job --- .github/workflows/main.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 2528638e..7ee85fe9 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -99,10 +99,10 @@ jobs: build: runs-on: ubuntu-latest needs: ['test'] + if: github.event_name == 'push' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v')) steps: - name: Publish to Docker Registry - if: github.event_name == 'push' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v')) uses: docker/build-push-action@v1 with: repository: simplelogin/app-ci @@ -111,7 +111,6 @@ jobs: tag_with_ref: true - name: Create Sentry release - if: github.event_name == 'push' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v')) uses: getsentry/action-release@v1 env: SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }} @@ -119,7 +118,6 @@ jobs: SENTRY_PROJECT: ${{ secrets.SENTRY_PROJECT }} - name: Send Telegram message - if: github.event_name == 'push' && github.ref == 'refs/heads/master' uses: appleboy/telegram-action@master with: to: ${{ secrets.TELEGRAM_TO }}