更新到.net8 #9
Workflow file for this run
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
name: .NET Core Desktop | |
on: | |
push: | |
tags: | |
- '*' | |
jobs: | |
build: | |
runs-on: windows-latest | |
name: Dotnet Build | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup dotnet | |
uses: actions/setup-dotnet@v1 | |
with: | |
dotnet-version: '8.0.*' | |
- run: dotnet publish -c Release --runtime win-x64 /p PublishAot=true --self-contained=true | |
- run: powershell curl https://github.com/aiqinxuancai/discord-proxy/releases/download/v0.0.10/x64.zip -o x64.zip | |
- run: powershell Expand-Archive -Path .\x64.zip -DestinationPath .\x64 | |
- run: powershell New-Item -ItemType Directory -Force -Path ".\build\x64" | |
- run: powershell Copy-Item -Path ".\x64\version.dll" -Destination ".\build\x64" | |
- run: powershell curl https://github.com/aiqinxuancai/discord-proxy/releases/download/v0.0.10/x86.zip -o x86.zip | |
- run: powershell Expand-Archive -Path .\x86.zip -DestinationPath .\x86 | |
- run: powershell New-Item -ItemType Directory -Force -Path ".\build\x86" | |
- run: powershell Copy-Item -Path ".\x86\version.dll" -Destination ".\build\x86" | |
- run: powershell Copy-Item -Path "$env:GITHUB_WORKSPACE\DiscordProxyStart\bin\Release\net7.0\win-x64\publish\DiscordProxyStart.exe" -Destination ".\build" | |
- run: powershell Copy-Item -Path "$env:GITHUB_WORKSPACE\DiscordProxyStart\bin\Release\net7.0\win-x64\publish\DiscordProxyStart.pdb" -Destination ".\build" | |
- run: powershell Copy-Item -Path "$env:GITHUB_WORKSPACE\DiscordProxyStart\bin\Release\net7.0\win-x64\publish\Config.ini" -Destination ".\build" | |
#- run: powershell Compress-Archive -Path "$env:GITHUB_WORKSPACE\DiscordProxyStart\bin\Release\net7.0\win-x64\publish\DiscordProxyStart.exe", ".\Release\version.dll" -DestinationPath .\DiscordProxyStart.zip | |
- run: powershell Compress-Archive -Path ".\build" -DestinationPath ".\DiscordProxyStart-win-amd64.zip" | |
- name: Create a Release | |
uses: ncipollo/release-action@v1 | |
with: | |
artifacts: "DiscordProxyStart-win-amd64.zip" | |
token: ${{ secrets.GITHUB_TOKEN }} | |