-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (36 loc) · 938 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
41
42
43
44
45
name: Publish to npm
on:
push:
tags:
- 'v*'
jobs:
release:
name: Release
runs-on: ubuntu-latest
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '18'
- name: Set up pnpm
uses: pnpm/action-setup@v4
with:
version: 7.32.4
- name: Install dependencies
run: pnpm i --frozen-lockfile
- name: Build package
run: pnpm build
- name: Set NPM profile for publishing packages
uses: franzbischoff/replace_envs@v1
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
with:
from_file: '.npmrc.template'
to_file: '.npmrc'
commit: 'false'
- name: Publish package
run: pnpm publish --access=public --no-git-checks