Skip to content

Commit b936935

Browse files
committed
chore: add github pages deploy action
1 parent d4c3fe4 commit b936935

File tree

1 file changed

+47
-0
lines changed

1 file changed

+47
-0
lines changed

.github/workflows/deploy.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Deploy to GitHub Pages
2+
3+
on:
4+
push:
5+
branches: [master]
6+
workflow_dispatch:
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Checkout
14+
uses: actions/checkout@v4
15+
16+
- name: Setup Node.js
17+
uses: actions/setup-node@v4
18+
with:
19+
node-version: 'latest'
20+
cache: 'pnpm'
21+
22+
- name: Setup pnpm
23+
uses: pnpm/action-setup@v4
24+
with:
25+
version: latest
26+
27+
- name: Install dependencies
28+
run: pnpm install --frozen-lockfile
29+
30+
- name: Build
31+
run: pnpm build
32+
33+
- name: Upload pages artifact
34+
uses: actions/upload-pages-artifact@v3
35+
with:
36+
path: ./dist
37+
38+
deploy:
39+
runs-on: ubuntu-latest
40+
needs: build
41+
permissions:
42+
pages: write
43+
id-token: write
44+
steps:
45+
- name: Deploy
46+
id: deployment
47+
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)