Skip to content

Commit

Permalink
Update dotnet.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
p6laris authored Jul 6, 2024
1 parent 6e12ee0 commit 85a3db5
Showing 1 changed file with 47 additions and 47 deletions.
94 changes: 47 additions & 47 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
@@ -1,50 +1,50 @@
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net

name: IOGesture.Test GitHub Pages

permissions:
contents: write

on:
push:
branches: [ "master" ]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x

- name: Add AOT Workload
run: |
dotnet workload install wasm-tools-net7
dotnet workload restore
- name: Restore dependencies
run: dotnet restore

- name: Build
run: dotnet build --no-restore

# publishes Blazor project to the release-folder
- name: Publish Blazor
run: dotnet publish ./IOGesture.Test/IOGesture.Test.csproj -c Release -o release --nologo

- name: Change base-tag in index.html from / to IOGesture.Test
run: sed -i 's/<base href="\/" \/>/<base href="\/IOGesture/IOGesture.Test/" \/>/g' release/wwwroot/index.html
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net

name: IOGesture.Test GitHub Pages

permissions:
contents: write
on:
push:
branches: [ "master" ]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Add AOT Workload
run: |
dotnet workload install wasm-tools-net7
dotnet workload restore
- name: Restore dependencies
run: dotnet restore ./IOGesture/IOGesture.Test/IOGesture.Test.csproj
- name: Build
run: dotnet build ./IOGesture/IOGesture.Test/IOGesture.Test.csproj --no-restore
# Publishes Blazor project to the release folder
- name: Publish Blazor
run: dotnet publish ./IOGesture/IOGesture.Test/IOGesture.Test.csproj -c Release -o release --nologo
- name: Change base-tag in index.html from / to /IOGesture/IOGesture.Test/
run: sed -i 's|<base href="/" />|<base href="/IOGesture/IOGesture.Test/" />|g' release/wwwroot/index.html

- name: Add .nojekyll file
run: touch release/wwwroot/.nojekyll
- name: Add .nojekyll file
run: touch release/wwwroot/.nojekyll

- name: Commit wwwroot to GitHub Pages
uses: JamesIves/[email protected]
with:
BRANCH: gh-pages
- name: Commit wwwroot to GitHub Pages
uses: JamesIves/[email protected]
with:
BRANCH: gh-pages
FOLDER: release/wwwroot

0 comments on commit 85a3db5

Please sign in to comment.