Skip to content

Commit e1dd21f

Browse files
jackblack369meilirensheng2020
authored andcommitted
[ci] Config artifact tag info
1 parent d5a30af commit e1dd21f

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

.github/workflows/ci-release.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Release Artifact
22

33
on:
44
push:
5-
branches: [ "main" ]
5+
branches: [ "**" ]
66
tags:
77
- '*'
88

@@ -17,6 +17,9 @@ jobs:
1717

1818
- name: Record event type
1919
run: |
20+
branchName=$(echo "${{ github.ref_name }}")
21+
echo "branch name is: $branchName"
22+
2023
echo "hello dingo eureka" > event.txt
2124
if [ "${{ github.event_name }}" == "pull_request" ]; then
2225
echo "EVENT_TYPE=PR" >> $GITHUB_ENV
@@ -27,7 +30,7 @@ jobs:
2730
echo "TAG_NAME=$tagInfo" >> $GITHUB_ENV
2831
else
2932
echo "EVENT_TYPE=PUSH" >> $GITHUB_ENV
30-
echo "TAG_NAME=latest" >> $GITHUB_ENV
33+
echo "TAG_NAME=${{ github.ref_name }}" >> $GITHUB_ENV
3134
fi
3235
fi
3336

0 commit comments

Comments
 (0)