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 : github pages
2+
3+ on :
4+ push :
5+ branches :
6+ - main
7+
8+ jobs :
9+ deploy :
10+ runs-on : ubuntu-latest
11+ steps :
12+ # Checkout the code
13+ - uses : actions/checkout@v4
14+
15+ # Install .NET SDK
16+ - name : Setup .NET SDK
17+ uses : actions/setup-dotnet@v4
18+ with :
19+ dotnet-version : " 10.0.x"
20+ dotnet-quality : " preview"
21+ - name : Install .NET WebAssembly Tools
22+ run : dotnet workload install wasm-tools
23+
24+ # Prepare for deployment to GitHub Pages
25+ - name : Add PublishSPAforGitHubPages.Build package
26+ run : dotnet add package PublishSPAforGitHubPages.Build
27+
28+ # Publish the site
29+ - name : Publish
30+ run : dotnet publish -f net10.0 -o public -p GHPages=true
31+
32+ # Deploy the site
33+ - name : Deploy
34+ uses : peaceiris/actions-gh-pages@v4
35+ with :
36+ github_token : ${{ secrets.GITHUB_TOKEN }}
37+ publish_dir : public/wwwroot
38+ force_orphan : true
You can’t perform that action at this time.
0 commit comments