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

craigrueda pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-superset.git


The following commit(s) were added to refs/heads/master by this push:
     new 8adc8b8  Quick fix for branch names in tags (#11930)
8adc8b8 is described below

commit 8adc8b886623f2413944dd7d68151185e3004d8d
Author: Craig Rueda <[email protected]>
AuthorDate: Fri Dec 4 14:27:25 2020 -0800

    Quick fix for branch names in tags (#11930)
---
 .github/workflows/docker_build_push.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/.github/workflows/docker_build_push.sh 
b/.github/workflows/docker_build_push.sh
index 3f7bfdc..dbfd134 100755
--- a/.github/workflows/docker_build_push.sh
+++ b/.github/workflows/docker_build_push.sh
@@ -21,14 +21,14 @@ SHA=$(git rev-parse HEAD)
 REPO_NAME="apache/incubator-superset"
 
 if [[ "${GITHUB_EVENT_NAME}" == "pull_request" ]]; then
-  REFSPEC="${GITHUB_HEAD_REF/[^a-zA-Z0-9]/-}"
+  REFSPEC=$(echo "${GITHUB_HEAD_REF}" | sed 's/[^a-zA-Z0-9]/-/' | head -c 20)
   PR_NUM=$(echo "${GITHUB_REF}" | sed 's:refs/pull/::' | sed 's:/merge::')
   LATEST_TAG="pr-${PR_NUM}"
 elif [[ "${GITHUB_EVENT_NAME}" == "release" ]]; then
   REFSPEC="${GITHUB_REF}"
   LATEST_TAG="${REFSPEC}"
 else
-  REFSPEC=$(echo "${GITHUB_REF}" | sed 's:refs/heads/::' | sed 
's/[^a-zA-Z0-9]/-/')
+  REFSPEC=$(echo "${GITHUB_REF}" | sed 's:refs/heads/::' | sed 
's/[^a-zA-Z0-9]/-/' | head -c 20)
   LATEST_TAG="${REFSPEC}"
 fi
 

Reply via email to