-
Notifications
You must be signed in to change notification settings - Fork 1
42 lines (33 loc) · 824 Bytes
/
release.yml
File metadata and controls
42 lines (33 loc) · 824 Bytes
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
41
42
name: Release
on:
push:
tags:
- 'v*'
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Set node
uses: actions/setup-node@v6
with:
node-version: [18.x, 20.x]
cache: npm
- run: npx changelogithub
continue-on-error: true
env:
GITHUB_TOKEN: ${{secrets.GH_TOKEN}}
- name: Install
run: npm install
- name: Build
run: npm run build
- name: Test
run: npm run test
- name: Config npm
run: echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > .npmrc
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Publish to npm
run: npm publish --access public --no-git-checks