This is an automated email from the ASF dual-hosted git repository.

zhangliang2022 pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git


The following commit(s) were added to refs/heads/main by this push:
     new 3ad939b8 fix: ci failed to non-semver tag (#2347)
3ad939b8 is described below

commit 3ad939b84461477a77f7e09949ced52d5baaaef5
Author: Klesh Wong <[email protected]>
AuthorDate: Fri Jun 24 10:31:30 2022 +0800

    fix: ci failed to non-semver tag (#2347)
---
 .github/workflows/build.yml | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index d90a4ecf..9a2900cd 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -30,7 +30,9 @@ jobs:
           docker build -t ${{ env.IMAGE_LAKE }}:latest --file ./Dockerfile .
           docker tag ${{ env.IMAGE_LAKE }}:latest ${{ env.IMAGE_LAKE }}:${{ 
github.ref_name }}
           docker push ${{ env.IMAGE_LAKE }}:${{ github.ref_name }}
-          printf {{ github.ref_name }} | grep -Pq '^v(\d+).(\d+).(\d+)$' && 
docker push ${{ env.IMAGE_LAKE }}:latest
+          if printf {{ github.ref_name }} | grep -Pq '^v(\d+).(\d+).(\d+)$'; 
then
+            docker push ${{ env.IMAGE_LAKE }}:latest
+          fi
   build-configui:
     name: Build config-ui image
     runs-on: ubuntu-20.04
@@ -53,7 +55,9 @@ jobs:
           docker build -t ${{ env.IMAGE_CONFIG_UI }}:latest --file 
./Dockerfile .
           docker tag ${{ env.IMAGE_CONFIG_UI }}:latest ${{ env.IMAGE_CONFIG_UI 
}}:${{ github.ref_name }}
           docker push ${{ env.IMAGE_CONFIG_UI }}:${{ github.ref_name }}
-          printf {{ github.ref_name }} | grep -Pq '^v(\d+).(\d+).(\d+)$' && 
docker push ${{ env.IMAGE_CONFIG_UI }}:latest
+          if printf {{ github.ref_name }} | grep -Pq '^v(\d+).(\d+).(\d+)$'; 
then
+            docker push ${{ env.IMAGE_CONFIG_UI }}:latest
+          fi
   build-grafana:
     name: Build grafana image
     runs-on: ubuntu-20.04
@@ -76,4 +80,6 @@ jobs:
           docker build -t ${{ env.IMAGE_GRAFANA }}:latest --file ./Dockerfile .
           docker tag ${{ env.IMAGE_GRAFANA }}:latest ${{ env.IMAGE_GRAFANA 
}}:${{ github.ref_name }}
           docker push ${{ env.IMAGE_GRAFANA }}:${{ github.ref_name }}
-          printf {{ github.ref_name }} | grep -Pq '^v(\d+).(\d+).(\d+)$' && 
docker push ${{ env.IMAGE_DASHBOARD }}:latest
+          if printf {{ github.ref_name }} | grep -Pq '^v(\d+).(\d+).(\d+)$'; 
then
+            docker push ${{ env.IMAGE_DASHBOARD }}:latest
+          fi

Reply via email to