Skip to content

[Upgrade]: handle navbar page admin to view component #20

[Upgrade]: handle navbar page admin to view component

[Upgrade]: handle navbar page admin to view component #20

Workflow file for this run

name: Build and Deploy Static Site to GitHub Pages
on:
push:
branches:
- main # Replace with your default branch
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Set up .NET
uses: actions/setup-dotnet@v2
with:
dotnet-version: '8.x' # Replace with your .NET version
- name: Restore dependencies
run: dotnet restore
- name: Build the project
run: dotnet build --configuration Release
- name: Publish the project
run: dotnet publish --configuration Release --output ./publish
- name: Generate static content
run: |
# Assuming you generate static files into the docs folder
# You might need a custom script to generate HTML from your Razor views.
# Here, we copy the content from publish to the docs folder as an example.
mkdir -p ./docs
cp -r ./publish/* ./docs/
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs # Directory where the static files are generated