-
Notifications
You must be signed in to change notification settings - Fork 1
57 lines (44 loc) · 1.13 KB
/
publish.yml
File metadata and controls
57 lines (44 loc) · 1.13 KB
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
46
47
48
49
50
51
52
53
54
55
56
57
name: Publish
on:
push:
branches: ["main"]
permissions:
id-token: write # Required for OIDC
contents: read
jobs:
build:
name: Build & Test & Publish
timeout-minutes: 5
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v3
with:
fetch-depth: 2
- uses: pnpm/action-setup@v2.0.1
with:
version: 10.15.0
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: 22
cache: "pnpm"
registry-url: "https://registry.npmjs.org"
- name: Update npm to latest version for OIDC support
run: npm install -g npm@latest
- name: Print versions
run: |
node --version
npm --version
- name: Install dependencies
run: pnpm install
- name: Build
run: pnpm build
- name: Lint
run: pnpm lint
- name: Test
run: pnpm test
- name: Publish Package
run: npm publish --tolerate-republish --no-fund --access public --provenance
env:
NPM_CONFIG_PROVENANCE: true