From e0e8a05ddca8e8217bda0b0a016e541482342d35 Mon Sep 17 00:00:00 2001 From: Alan Tang Date: Tue, 10 Dec 2024 02:05:23 +0800 Subject: [PATCH] bug: fix push-latest-images and publish-release (#279) Signed-off-by: Alan Tang --- .github/workflows/default.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/default.yaml b/.github/workflows/default.yaml index c1953237..7138e444 100644 --- a/.github/workflows/default.yaml +++ b/.github/workflows/default.yaml @@ -59,7 +59,7 @@ jobs: args: build-dev --platform linux/amd64 export --path=./harbor-dev push-latest-images: - if: github.event.pull_request == null && !startsWith(github.ref, 'refs/tags/v') + if: github.event_name == 'push' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/')) needs: - lint - test-code @@ -84,7 +84,7 @@ jobs: publish-release: - if: startsWith(github.ref, 'refs/tags/v') + if: github.event_name == 'push' && (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/')) needs: - lint - test-code