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 React App to GitHub Pages
2+ on :
3+ push :
4+ branches : [main]
5+ jobs :
6+ build :
7+ runs-on : ubuntu-latest
8+ steps :
9+ - name : Checkout code
10+ uses : actions/checkout@v3
11+ - name : Setup Node.js
12+ uses : actions/setup-node@v3
13+ with :
14+ node-version : 18
15+ - name : Install dependencies
16+ run : cd logic-editor && npm install
17+ - name : Build React app
18+ run : cd logic-editor && npm run build
19+ - name : Upload artifact
20+ uses : actions/upload-pages-artifact@v1
21+ with :
22+ path : logic-editor/build/ # Path to built files
23+ deploy :
24+ needs : build
25+ permissions :
26+ pages : write
27+ id-token : write
28+ environment :
29+ name : github-pages
30+ url : ${{ steps.deployment.outputs.page_url }}
31+ runs-on : ubuntu-latest
32+ steps :
33+ - name : Deploy to GitHub Pages
34+ id : deployment
35+ uses : actions/deploy-pages@v1
You can’t perform that action at this time.
0 commit comments