Skip to content

feat: 更新主布局,替换品牌图标并添加加载动画 #4

feat: 更新主布局,替换品牌图标并添加加载动画

feat: 更新主布局,替换品牌图标并添加加载动画 #4

Workflow file for this run

name: Deploy Demo To GitHub Pages
on:
push:
branches: [ "main" ]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: pages
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout demo
uses: actions/checkout@v6
with:
path: demo-source
- name: Checkout Element-Blazor sources
uses: actions/checkout@v6
with:
repository: Element-Blazor/Element-Blazor
path: element-blazor
submodules: recursive
- name: Overlay demo submodule
shell: bash
run: |
rm -rf element-blazor/demo
mkdir -p element-blazor/demo
tar --exclude='./.git' -C demo-source -cf - . | tar -C element-blazor/demo -xf -
- name: Setup .NET
uses: actions/setup-dotnet@v5
with:
dotnet-version: "10.0.x"
- name: Configure Pages
uses: actions/configure-pages@v6
- name: Install WebAssembly workload
run: dotnet workload install wasm-tools
- name: Restore demo site
run: dotnet restore demo/site/Element.ClientRender.csproj
working-directory: element-blazor
- name: Publish demo site
run: dotnet publish demo/site/Element.ClientRender.csproj -c Release -o ../artifacts/site --no-restore
working-directory: element-blazor
- name: Prepare Pages artifact
shell: bash
run: |
touch artifacts/site/wwwroot/.nojekyll
cp artifacts/site/wwwroot/index.html artifacts/site/wwwroot/404.html
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v4
with:
path: artifacts/site/wwwroot
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
needs: build
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v5