-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (34 loc) · 969 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
34
35
36
37
38
39
40
name: Publish to NPM
on:
push:
branches:
- master
jobs:
publish:
runs-on: [ubuntu-latest]
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Setup Node
uses: actions/setup-node@v1
with:
node-version: 20
registry-url: https://registry.npmjs.org/
- uses: paulhatch/[email protected]
id: semver
- name: Build & Tag
run: |
npm install
npm run build
npm version ${{ steps.semver.outputs.version }} --no-git-tag-version
- name: Publish to NPM
uses: JS-DevTools/npm-publish@v2
with:
token: ${{ secrets.NPM_TOKEN }}
- name: Publish Github Release
uses: softprops/action-gh-release@v1
with:
tag_name: v${{ steps.semver.outputs.version }}
draft: false