diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml new file mode 100644 index 0000000..ad942cb --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,29 @@ +name: Deploy to GitHub Pages + +on: + workflow_dispatch: + +jobs: + deploy: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - name: Install WASM tools + run: dotnet workload install wasm-tools + + - name: Publish + run: dotnet publish DotnetEventViewer --configuration Release -o publish + + - name: Change base href + run: sed -i 's///g' publish/wwwroot/index.html + + # Bypass Jekyll processing to allow directories starting with underscores + - name: Add .nojekyll file + run: touch publish/wwwroot/.nojekyll + + - name: Commit wwwroot to GitHub Pages + uses: JamesIves/github-pages-deploy-action@3.7.1 + with: + branch: gh-pages + folder: publish/wwwroot