Skip to content

Commit 8f62093

Browse files
committed
feat: added auto release
1 parent 7bcce81 commit 8f62093

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: "Semantic Release"
2+
3+
on:
4+
push:
5+
branches:
6+
- ([0-9])?(.{+([0-9]),x}).x
7+
- master
8+
- next
9+
- next-major
10+
- alpha
11+
- beta
12+
13+
jobs:
14+
semantic-release:
15+
name: "Semantic Release"
16+
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
- name: Checkout
21+
uses: actions/checkout@v3
22+
- name: Semantic Release
23+
uses: cycjimmy/semantic-release-action@v3
24+
id: semantic # Need an `id` for output variables
25+
env:
26+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27+
NPM_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
28+
29+
- name: Do something when a new release published
30+
if: steps.semantic.outputs.new_release_published == 'true'
31+
run: |
32+
echo ${{ steps.semantic.outputs.new_release_version }}
33+
echo ${{ steps.semantic.outputs.new_release_major_version }}
34+
echo ${{ steps.semantic.outputs.new_release_minor_version }}
35+
echo ${{ steps.semantic.outputs.new_release_patch_version }}

0 commit comments

Comments
 (0)