File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Deploy Support-Us-Button to GitHub Pages
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+
8+ workflow_dispatch :
9+
10+ permissions :
11+ contents : read
12+ pages : write
13+ id-token : write
14+
15+ concurrency :
16+ group : " pages"
17+ cancel-in-progress : false
18+
19+ jobs :
20+ build :
21+ runs-on : ubuntu-latest
22+
23+ steps :
24+ - name : Checkout
25+ uses : actions/checkout@v4
26+
27+ - name : Setup Node.js
28+ uses : actions/setup-node@v4
29+ with :
30+ node-version : 22
31+ cache : npm
32+
33+ - name : Setup Pages
34+ uses : actions/configure-pages@v5
35+
36+ - name : Install dependencies
37+ run : npm ci
38+
39+ - name : Build
40+ run : npm run vite:build
41+
42+ - name : Upload artifact
43+ uses : actions/upload-pages-artifact@v3
44+ with :
45+ path : ./dist
46+
47+ deploy :
48+ environment :
49+ name : github-pages
50+ url : ${{ steps.deployment.outputs.page_url }}
51+
52+ runs-on : ubuntu-latest
53+ needs : build
54+
55+ steps :
56+ - name : Deploy to GitHub Pages
57+ id : deployment
58+ uses : actions/deploy-pages@v4
Original file line number Diff line number Diff line change 5858 "build:js" : " rollup -c" ,
5959 "build" : " npm run build:css && npm run build:js" ,
6060 "dev" : " rollup -c -w" ,
61- "dev:demo" : " vite" ,
61+ "vite:dev" : " vite" ,
62+ "vite:build" : " vite build" ,
63+ "vite:preview" : " vite preview" ,
6264 "type-check" : " tsc --noEmit" ,
6365 "test" : " npm run type-check && vitest run --passWithNoTests" ,
6466 "prepublishOnly" : " npm run build"
You can’t perform that action at this time.
0 commit comments