over ci fix #2
This file contains hidden or 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: Build | |
| on: | |
| push: | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| runs-on: windows-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| submodules: true | |
| - name: Setup MSBuild | |
| uses: microsoft/setup-msbuild@v2 | |
| - uses: nuget/setup-nuget@v2 | |
| with: | |
| nuget-version: latest | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: 3.13 | |
| - name: Configure Git to use HTTPS | |
| run: git config --global url."https://github.com/".insteadOf git://github.com/ | |
| - name: Generate resources | |
| shell: pwsh | |
| run: | | |
| cd translate | |
| pip install -r requirements.txt | |
| python po2ymo.py ./source/zh_CN.po ./generated/zh_CN.ymo | |
| python po2ymo.py ./source/zh_TW.po ./generated/zh_TW.ymo | |
| @" | |
| #include "../../targetver.h" | |
| #include "windows.h" | |
| LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED | |
| 1 YMO "zh_CN.ymo" | |
| LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_TRADITIONAL | |
| 1 YMO "zh_TW.ymo" | |
| "@ | Out-File -FilePath ./generated/translate.rc -Encoding utf8 | |
| - name: Restore NuGet packages | |
| run: nuget restore AudioPlaybackConnector.sln | |
| - name: Build Solution | |
| run: | | |
| Start-Job -Init ([ScriptBlock]::Create("Set-Location '$pwd'")) -Script { | |
| msbuild AudioPlaybackConnector.sln "-p:Configuration=Release;Platform=x64" } | |
| Start-Job -Init ([ScriptBlock]::Create("Set-Location '$pwd'")) -Script { | |
| msbuild AudioPlaybackConnector.sln "-p:Configuration=Release;Platform=x86" } | |
| Start-Job -Init ([ScriptBlock]::Create("Set-Location '$pwd'")) -Script { | |
| msbuild AudioPlaybackConnector.sln "-p:Configuration=Release;Platform=ARM64" } | |
| Start-Job -Init ([ScriptBlock]::Create("Set-Location '$pwd'")) -Script { | |
| msbuild AudioPlaybackConnector.sln "-p:Configuration=Release;Platform=ARM" } | |
| Get-Job | Wait-Job | Receive-Job | |
| shell: powershell | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: AudioPlaybackConnector64exe | |
| path: x64/Release/AudioPlaybackConnector64.exe | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: AudioPlaybackConnector64pdb | |
| path: x64/Release/AudioPlaybackConnector64.pdb | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: AudioPlaybackConnector32exe | |
| path: Release/AudioPlaybackConnector32.exe | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: AudioPlaybackConnector32pdb | |
| path: Release/AudioPlaybackConnector32.pdb | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: AudioPlaybackConnectorARM64exe | |
| path: ARM64/Release/AudioPlaybackConnectorARM64.exe | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: AudioPlaybackConnectorARM64pdb | |
| path: ARM64/Release/AudioPlaybackConnectorARM64.pdb | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: AudioPlaybackConnectorARMexe | |
| path: ARM/Release/AudioPlaybackConnectorARM.exe | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: AudioPlaybackConnectorARMpdb | |
| path: ARM/Release/AudioPlaybackConnectorARM.pdb | |
| - name: Release | |
| uses: softprops/action-gh-release@v2 | |
| if: github.ref_type == 'tag' | |
| with: | |
| files: | | |
| x64/Release/AudioPlaybackConnector64.exe | |
| Release/AudioPlaybackConnector32.exe | |
| ARM64/Release/AudioPlaybackConnectorARM64.exe | |
| ARM/Release/AudioPlaybackConnectorARM.exe | |
| tag_name: ${{ github.ref }} | |
| release_name: ${{ github.ref }} | |
| draft: true | |
| prerelease: false |