Skip to content

Commit efba4b7

Browse files
committed
new: release will now create GH release
1 parent 7938ef5 commit efba4b7

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

.github/workflows/publish.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@ on:
1414

1515
jobs:
1616
release:
17+
permissions:
18+
contents: write
19+
1720
# Use the semver as the job name
1821
name: "Release ${{ github.event.inputs.semver }}"
1922
runs-on: ubuntu-latest
@@ -36,9 +39,21 @@ jobs:
3639
git config --local user.email "[email protected]"
3740
git config --local user.name "GitHub Action"
3841
npm version ${{ github.event.inputs.semver }}
42+
VERSION=`cat package.json | grep version | tr -d " " | cut -d":" -f2 | tr -d "\","` >> $GITHUB_ENV
3943
git push && git push --tags
4044
4145
- name: Publish
4246
run: npm publish
4347
env:
4448
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
49+
50+
- uses: actions/create-release@v1
51+
name: Release
52+
id: create_release
53+
env:
54+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
55+
with:
56+
tag_name: ${{ env.VERSION }}
57+
release_name: Release ${{ env.VERSION }}
58+
draft: false
59+
prerelease: false

0 commit comments

Comments
 (0)