-
-
Notifications
You must be signed in to change notification settings - Fork 139
78 lines (69 loc) · 1.93 KB
/
release_wasm.yml
File metadata and controls
78 lines (69 loc) · 1.93 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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
name: Release WASM
on:
push:
branches:
- main
permissions:
contents: write
id-token: write
pull-requests: write
jobs:
release:
name: Release
runs-on: macos-14
steps:
- name: Checkout Repo
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10
- name: Setup node
uses: actions/setup-node@v6
with:
node-version: 24
cache: pnpm
registry-url: "https://registry.npmjs.org"
- name: Upgrade npm for trusted publishing
run: |
corepack enable
corepack prepare npm@latest --activate
npm --version
- name: Setup Bun
uses: oven-sh/setup-bun@v1
with:
bun-version: 1.3.0
- name: Setup Deno
uses: denoland/setup-deno@v1
with:
deno-version: v2.x
- name: Install wasm-opt
run: npm i wasm-opt -g
- uses: jetli/wasm-pack-action@v0.4.0
with:
# Optional version of wasm-pack to install(eg. 'v0.9.1', 'latest')
version: "latest"
- name: Install nextest
uses: taiki-e/install-action@v1
with:
tool: nextest
- run: rustup toolchain install 1.83.0 --profile minimal
- run: rustup target add wasm32-unknown-unknown
- uses: jetli/wasm-bindgen-action@v0.2.0
with:
version: "0.2.100"
- uses: Swatinem/rust-cache@v2
- name: Build WASM release-build
run: pnpm release-wasm
- name: Create Release Pull Request or Publish to npm
id: changesets
uses: changesets/action@v1
with:
title: "chore: version packages"
commit: "chore: version packages"
version: pnpm run ci-release-wasm-version
publish: pnpm run ci-release-wasm-publish
env:
GITHUB_TOKEN: ${{ github.token }}