Skip to content

Update to .NET 8 and include source-link bar. #213

Update to .NET 8 and include source-link bar.

Update to .NET 8 and include source-link bar. #213

Workflow file for this run

name: 'Publish application'
on:
push:
branches:
- main
paths-ignore:
- '**/README.md'
jobs:
build:
runs-on: ubuntu-latest
steps:
# Checkout the code
- uses: actions/checkout@v2
# Install .NET SDK
- name: Setup .NET 8
uses: actions/setup-dotnet@v1
with:
dotnet-version: '8.0.x'
include-prerelease: true
# Add Nuget.Config to solution
#- name: Install Nuget configs
# run: |
# dotnet new nugetconfig
# dotnet nuget add source -n dotnet6 https://dnceng.pkgs.visualstudio.com/public/_packaging/dotnet6/nuget/v3/index.json
# Added Ahead-Of-Time workload
- name: Add AOT Workload
run: dotnet workload install wasm-tools
# Run tests
- name: Test
run: dotnet test ./test/KristofferStrube.Blazor.SvgEditor.Test/
# Generate the website
- name: Publish
run: dotnet publish samples/KristofferStrube.Blazor.SVGEditor.WasmExample/KristofferStrube.Blazor.SVGEditor.WasmExample.csproj --configuration Release --output build
# Publish the website
- name: GitHub Pages action
if: ${{ github.ref == 'refs/heads/main' }} # Publish only when the push is on main
uses: peaceiris/actions-gh-pages@v3.6.1
with:
github_token: ${{ secrets.PUBLISH_TOKEN }}
publish_branch: gh-pages
publish_dir: build/wwwroot
allow_empty_commit: false
keep_files: false
force_orphan: true