mirror of
https://github.com/nezhahq/nezha.git
synced 2025-02-02 01:28:13 -05:00
Update release workflow to extract tag name
This commit is contained in:
parent
0e91a00076
commit
efa9a30a3a
8
.github/workflows/release.yml
vendored
8
.github/workflows/release.yml
vendored
@ -14,12 +14,8 @@ jobs:
|
||||
|
||||
- name: Extract branch name
|
||||
run: |
|
||||
export BRANCH_NAME=$(echo ${GITHUB_REF#refs/heads/})
|
||||
echo "##[set-output name=branch;]$BRANCH_NAME"
|
||||
if [ $BRANCH_NAME = "main" ] || [ $BRANCH_NAME = "master" ]
|
||||
then echo "##[set-output name=tag;]latest"
|
||||
else echo "##[set-output name=tag;]$BRANCH_NAME"
|
||||
fi
|
||||
export TAG_NAME=$(echo ${GITHUB_REF#refs/tags/})
|
||||
echo "tag=$TAG_NAME" >> $GITHUB_OUTPUT
|
||||
id: extract_branch
|
||||
|
||||
- name: xgo build
|
||||
|
Loading…
Reference in New Issue
Block a user