Files
AppleMusicDecrypt/.github/workflows/win-build.yml
世界观察日志 4df575d0c1
Some checks failed
/ Build Windows (push) Has been cancelled
Update win-build.yml
workflow: use WinPython for virtual environment setup on Windows
2025-06-26 19:45:23 +08:00

32 lines
1.2 KiB
YAML

on:
push:
branches:
- v2
workflow_dispatch:
jobs:
build_winodws:
name: Build Windows
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Create venv
run: |
Invoke-WebRequest -Uri "https://github.com/winpython/winpython/releases/download/16.6.20250620/Winpython64-3.12.10.1dotrc.zip" -OutFile winpy.zip
$td="$env:TEMP";Expand-Archive .\winpy.zip $td;if(-not(Test-Path .\.venv)){New-Item -ItemType Directory .\.venv | Out-Null};Copy-Item "$td\WPy64-312101\python\*" .\.venv -Recurse -Force;Remove-Item "$td\WPy64-312101" -Recurse -Force;Remove-Item .\winpy.zip -Recurse -Force
- name: Install dependencies
run: |
.\.venv\python.exe -m pip install poetry
.\.venv\python.exe -m poetry install
- name: Prepare environment
run: |
cp config.example.toml config.toml
echo ".\.venv\python.exe main.py" > start.ps1
echo ".venv\python.exe main.py" > start.bat
- name: Upload CLI artifact
uses: actions/upload-artifact@v4
with:
name: AppleMusicDecrypt-Windows
path: .
include-hidden-files: true