feat: 支持使用虚拟终端启动服务器 #69
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
push: | |
paths: | |
- "**.cs" | |
- "**.csproj" | |
workflow_dispatch: | |
permissions: | |
id-token: write | |
attestations: write | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.head_ref }} | |
- name: Install .NET | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: 8.0.x | |
- name: Publish the solution | |
run: ./src/Scripts/publish.bat | |
# Serein.Lite | |
- name: Upload binary files(Serein.Lite_win-x64) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Serein.Lite_win-x64 | |
path: ./src/Serein.Lite/bin/Release/net8.0-windows/win-x64/publish | |
# Serein.Plus | |
- name: Upload binary files(Serein.Plus_win-x64) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Serein.Plus_win-x64 | |
path: ./src/Serein.Plus/bin/Release/net8.0-windows/win-x64/publish | |
# Serein.Cli | |
- name: Upload binary files(Serein.Cli_win-x64) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Serein.Cli_win-x64 | |
path: ./src/Serein.Cli/bin/Release/net8.0/win-x64/publish | |
- name: Upload binary files(Serein.Cli_linux-x64) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Serein.Cli_linux-x64 | |
path: ./src/Serein.Cli/bin/Release/net8.0/linux-x64/publish | |
- name: Upload binary files(Serein.Cli_linux-arm) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Serein.Cli_linux-arm | |
path: ./src/Serein.Cli/bin/Release/net8.0/linux-arm/publish | |
- name: Upload binary files(Serein.Cli_linux-arm64) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Serein.Cli_linux-arm64 | |
path: ./src/Serein.Cli/bin/Release/net8.0/linux-arm64/publish | |
- name: Upload binary files(Serein.Cli_osx-x64) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Serein.Cli_osx-x64 | |
path: ./src/Serein.Cli/bin/Release/net8.0/osx-x64/publish | |
- name: Upload binary files(Serein.Cli_osx-arm64) | |
uses: actions/upload-artifact@v4 | |
with: | |
name: Serein.Cli_osx-arm64 | |
path: ./src/Serein.Cli/bin/Release/net8.0/osx-arm64/publish | |
attest-build-provenance: | |
needs: [ build ] | |
runs-on: windows-latest | |
strategy: | |
matrix: | |
names: [ Serein.Lite_win-x64, Serein.Plus_win-x64, Serein.Cli_win-x64, Serein.Cli_linux-x64, Serein.Cli_linux-arm, Serein.Cli_osx-x64, Serein.Cli_osx-arm64 ] | |
steps: | |
- uses: actions/download-artifact@v4 | |
with: | |
path: downloads | |
name: ${{ matrix.names }} | |
- shell: powershell | |
run: | | |
Remove-Item ./downloads/* -Exclude *.exe,*.Cli -Recurse | |
- uses: actions/attest-build-provenance@v1 | |
continue-on-error: true | |
with: | |
subject-path: downloads/* | |
subject-name: ${{ matrix.names }} | |