File tree Expand file tree Collapse file tree 1 file changed +59
-0
lines changed
Expand file tree Collapse file tree 1 file changed +59
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Deploy React to GitHub Pages
2+
3+ on :
4+ push :
5+ tags :
6+ - ' web-v*'
7+ workflow_dispatch :
8+
9+ permissions :
10+ contents : read
11+ pages : write
12+ id-token : write
13+
14+ concurrency :
15+ group : " pages"
16+ cancel-in-progress : false
17+
18+ jobs :
19+ build :
20+ runs-on : ubuntu-latest
21+ steps :
22+ - name : Checkout 🛎️
23+ uses : actions/checkout@v4
24+ with :
25+ ref : web
26+
27+ - name : Setup Node.js 📦
28+ uses : actions/setup-node@v4
29+ with :
30+ node-version : ' 20'
31+ cache : ' npm'
32+ cache-dependency-path : ' web/package-lock.json'
33+
34+ - name : Install dependencies 🔧
35+ run : npm ci
36+ working-directory : web
37+
38+ - name : Build 🏗️
39+ run : npm run build
40+ working-directory : web
41+
42+ - name : Setup Pages 📄
43+ uses : actions/configure-pages@v4
44+
45+ - name : Upload artifact 📤
46+ uses : actions/upload-pages-artifact@v3
47+ with :
48+ path : ' web/dist'
49+
50+ deploy :
51+ environment :
52+ name : github-pages
53+ url : ${{ steps.deployment.outputs.page_url }}
54+ runs-on : ubuntu-latest
55+ needs : build
56+ steps :
57+ - name : Deploy to GitHub Pages 🚀
58+ id : deployment
59+ uses : actions/deploy-pages@v4
You can’t perform that action at this time.
0 commit comments