File tree Expand file tree Collapse file tree 1 file changed +33
-0
lines changed
Expand file tree Collapse file tree 1 file changed +33
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Deploy Angular app to GitHub Pages
2+
3+ on :
4+ push :
5+ branches : [ main ]
6+ workflow_dispatch :
7+
8+ jobs :
9+ build-and-deploy :
10+ runs-on : ubuntu-latest
11+
12+ steps :
13+ - name : Checkout
14+ uses : actions/checkout@v3
15+
16+ - name : Set up Node.js
17+ uses : actions/setup-node@v3
18+ with :
19+ node-version : 18
20+ cache : ' npm'
21+
22+ - name : Install dependencies
23+ run : npm ci
24+
25+ - name : Build
26+ run : npm run build -- --configuration production --base-href="/${{ github.event.repository.name }}/"
27+
28+ - name : Deploy to GitHub Pages
29+ uses : JamesIves/github-pages-deploy-action@v4
30+ with :
31+ folder : dist/$(grep -m 1 "outputPath" angular.json | awk -F: '{print $2}' | sed 's/[", ]//g')
32+ token : ${{ secrets.GITHUB_TOKEN }}
33+ branch : gh-pages
You can’t perform that action at this time.
0 commit comments