Fix #5 and #6 #55
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy to GitHub Pages | |
# Controls when the action will run. Triggers the workflow on push or pull request | |
# events but only for the master branch | |
on: | |
push: | |
branches: [ main ] | |
paths-ignore: | |
- '**/README.md' | |
pull_request: | |
branches: [ main ] | |
paths-ignore: | |
- '**/README.md' | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
# Checkout the code | |
- uses: actions/checkout@v4 | |
# Install .NET Core SDK | |
- name: Setup .NET Core | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: 8.0.x | |
# Publish the site | |
- name: Publish | |
run: dotnet publish src/GPXRide.csproj -c Release -o public -p:GHPages=true -p:PublishTrimmed=false | |
# Deploy the site | |
- name: Deploy | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: public/wwwroot | |
force_orphan: true |