File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -33,11 +33,15 @@ jobs:
33
33
run : cc-test-reporter after-build
34
34
env :
35
35
CC_TEST_REPORTER_ID : ${{secrets.CC_TEST_REPORTER_ID}}
36
- - name : Test release
36
+ - name : Release
37
+ if : github.ref == 'refs/heads/master'
38
+ id : semantic
39
+ uses : cycjimmy/semantic-release-action@v2
37
40
env :
38
41
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
39
- run : npx semantic-release --dry-run --branch ${GITHUB_REF##*/}
40
- - name : Release
41
- run : npx semantic-release # this only runs on master and develop. see .releaserc.js
42
+ - name : Update major version tag (e.g., v1)
43
+ if : github.ref == 'refs/heads/master'
44
+ run : git tag -f v${MAJOR_VERSION} && git push origin v${MAJOR_VERSION}
42
45
env :
43
- GITHUB_TOKEN : ${{secrets.GITHUB_TOKEN}}
46
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
47
+ MAJOR_VERSION : ${{ steps.semantic.outputs.new_release_major_version }}
You can’t perform that action at this time.
0 commit comments