-
-
Notifications
You must be signed in to change notification settings - Fork 2
59 lines (51 loc) · 1.52 KB
/
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
name: Release
permissions:
contents: read
on:
workflow_dispatch:
push:
branches:
- main
- next
- alpha
- beta
jobs:
release:
permissions:
contents: write # to be able to publish a GitHub release
issues: write # to be able to comment on released issues
pull-requests: write # to be able to comment on released pull requests
id-token: write # to enable use of OIDC for npm provenance
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
# run before Set node , otherwise show Unable to locate executable file: pnpm error
- name: Use just
- uses: extractions/setup-just@v2
- name: Use bun
- uses: oven-sh/setup-bun@v2
- name: Set node
uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
registry-url: 'https://registry.npmjs.org'
- name: Install Dependencies
run: npm install
- name: Build
run: just build
- name: Test
run: just test
- uses: codecov/codecov-action@v4
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
# https://github.com/semantic-release/semantic-release/issues/2313
# continue-on-error: true
# - name: Publish to NPM
# run: pnpm publish --access public --no-git-checks
# env:
# NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
# NPM_CONFIG_PROVENANCE: true