Skip to content

Commit a6cb821

Browse files
Kaleidosiumpigpigyyy
authored andcommitted
Switch from yarn to pnpm
1 parent db769a1 commit a6cb821

4 files changed

Lines changed: 1829 additions & 18 deletions

File tree

.github/workflows/static.yml

Lines changed: 40 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
1-
# Simple workflow for deploying static content to GitHub Pages
21
name: Deploy static content to Pages
32

43
on:
5-
6-
# Allows you to run this workflow manually from the Actions tab
74
workflow_dispatch:
85

96
permissions:
@@ -20,25 +17,54 @@ jobs:
2017
environment:
2118
name: github-pages
2219
url: ${{ steps.deployment.outputs.page_url }}
23-
runs-on: macos-latest
20+
runs-on: ubuntu-latest
2421
steps:
2522
- name: Checkout
26-
uses: actions/checkout@v4
27-
- name: Setup Pages
28-
uses: actions/configure-pages@v5
29-
- name: Prepare Site
23+
uses: actions/checkout@v6
24+
25+
- name: Cache Emscripten
26+
uses: actions/cache@v4
27+
with:
28+
path: ~/emsdk
29+
key: emsdk-${{ runner.os }}-latest
30+
31+
- name: Install Emscripten
32+
run: |
33+
git clone https://github.com/emscripten-core/emsdk.git ~/emsdk
34+
~/emsdk/emsdk install latest
35+
~/emsdk/emsdk activate latest
36+
37+
- name: Build WASM
3038
run: |
31-
brew upgrade -f python
32-
brew install emscripten
39+
source ~/emsdk/emsdk_env.sh
3340
make wasm
41+
42+
- name: Setup pnpm
43+
uses: pnpm/action-setup@v4
44+
with:
45+
version: 10
46+
47+
- name: Setup Node
48+
uses: actions/setup-node@v6
49+
with:
50+
node-version: 20
51+
cache: 'pnpm'
52+
cache-dependency-path: doc/pnpm-lock.yaml
53+
54+
- name: Install and build docs
55+
run: |
3456
cd doc
35-
yarn
36-
yarn build
37-
cd ..
57+
pnpm install
58+
pnpm run build
59+
60+
- name: Setup Pages
61+
uses: actions/configure-pages@v5
62+
3863
- name: Upload artifact
3964
uses: actions/upload-pages-artifact@v3
4065
with:
4166
path: 'doc/docs/.vitepress/dist'
67+
4268
- name: Deploy to GitHub Pages
4369
id: deployment
44-
uses: actions/deploy-pages@v4
70+
uses: actions/deploy-pages@v4

doc/.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,5 @@ dist
1010
.basement
1111
config.local.js
1212
basement_dist
13-
yarn.lock
1413
docs/.vitepress/public/js/yuescript.js
1514
docs/.vitepress/public/js/yuescript.wasm

doc/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
## Development
66

77
```bash
8-
yarn dev
9-
yarn build
10-
yarn preview
8+
pnpm run dev
9+
pnpm run build
10+
pnpm run preview
1111
```
1212

1313
For more details, please head to VitePress's [documentation](https://vitepress.dev/).

0 commit comments

Comments
 (0)