-
Notifications
You must be signed in to change notification settings - Fork 12
37 lines (30 loc) · 1.16 KB
/
gh-pages.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: gh-pages
on:
push:
branches:
- master
permissions:
contents: write
jobs:
build:
concurrency: ci-${{ github.ref }} # Recommended if you intend to make multiple deployments in quick succession.
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 7.0.x
- name: Publish with dotnet
run: dotnet publish apps/nostr-debug/NostrDebug.Web -f net7.0 --configuration Release --output build
# copy index.html to 404.html to serve the same file when a file is not found
- name: Copy index.html to 404.html
run: cp build/wwwroot/index.html build/wwwroot/404.html
# add .nojekyll file to tell GitHub pages to not treat this as a Jekyll project. (Allow files and folders starting with an underscore)
- name: Add .nojekyll file
run: touch build/wwwroot/.nojekyll
- name: Deploy to Github Pages
uses: JamesIves/github-pages-deploy-action@v4
with:
branch: gh-pages # The branch the action should deploy to.
folder: build/wwwroot # The folder the action should deploy.