File tree Expand file tree Collapse file tree 1 file changed +12
-12
lines changed
.github/actions/build-nix-image Expand file tree Collapse file tree 1 file changed +12
-12
lines changed Original file line number Diff line number Diff line change @@ -63,20 +63,20 @@ runs:
6363 if [ "${{ inputs.triggerEventName }}" == "pull_request" ]; then
6464 echo "GIT_SHA=$CI_GITHUB_EVENT_PULL_REQUEST_HEAD_SHA" >> $GITHUB_ENV
6565 echo "GIT_SHA_SHORT=$CI_GITHUB_EVENT_PULL_REQUEST_HEAD_SHA_SHORT" >> $GITHUB_ENV
66- # elif [ -n "${{ inputs.releaseVersion }}" ]; then
67- # tag_base="${{ inputs.releaseVersion }}"
68-
69- # if [[ $tag_base =~ ^[0-9] ]]; then
70- # tag="v$tag_base"
71- # else
72- # tag="$tag_base"
73- # fi
66+ elif [ -n "${{ inputs.releaseVersion }}" ]; then
67+ tag_base="${{ inputs.releaseVersion }}"
68+ echo "tag_base=$tag_base"
69+ if [[ $tag_base =~ ^[0-9] ]]; then
70+ tag="v$tag_base"
71+ else
72+ tag="$tag_base"
73+ fi
7474
75- # sha=$(git rev-parse "$tag")
76- # short_sha=$(git rev-parse --short "$tag")
75+ sha=$(git rev-parse "$tag")
76+ short_sha=$(git rev-parse --short "$tag")
7777
78- # echo "GIT_SHA=$sha" >> $GITHUB_ENV
79- # echo "GIT_SHA_SHORT=$short_sha" >> $GITHUB_ENV
78+ echo "GIT_SHA=$sha" >> $GITHUB_ENV
79+ echo "GIT_SHA_SHORT=$short_sha" >> $GITHUB_ENV
8080 else
8181 echo "GIT_SHA=$CI_GITHUB_SHA" >> $GITHUB_ENV
8282 echo "GIT_SHA_SHORT=$CI_GITHUB_SHA_SHORT" >> $GITHUB_ENV
You can’t perform that action at this time.
0 commit comments