-
Notifications
You must be signed in to change notification settings - Fork 7
33 lines (29 loc) · 916 Bytes
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: Release
on:
push:
branches: [ main ]
workflow_dispatch:
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Configure user
run: |
git config --global user.email "[email protected]"
git config --global user.name "Github Actions"
- run: cd $GITHUB_WORKSPACE
- name: echo version
run: |
git remote update
git tag -l
- name: Tag and Publish
run: git tag -l | grep v$(make version) || make publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: GitHub Tag Name example
run: |
git checkout tags/v$(make version)
echo "Tag name from GITHUB_REF_NAME: $GITHUB_REF_NAME"
echo "Tag name from github.ref_name: ${{ github.ref_name }}"
echo "Tag name from github.ref_name: ${{ github.ref_name }}"