diff --git a/.github/workflows/build-exe.yml b/.github/workflows/build-exe.yml index 9cdea71..0373877 100644 --- a/.github/workflows/build-exe.yml +++ b/.github/workflows/build-exe.yml @@ -39,25 +39,19 @@ jobs: # 步骤3:安装 Python(使用正确的文件名) - name: Install Python in Wine run: | - # 使用绝对路径并添加调试信息 echo "Current directory: $(pwd)" - echo "Files in current directory:" - ls -la - - # 确保文件存在 - if [ ! -f "python-3.9.9-amd64.exe" ]; then + ls -lah + + if [ ! -f python-3.9.9-amd64.exe ]; then echo "Installer not found!" exit 1 fi - - # 尝试用 wineconsole 而不是 wine,有时更稳定 - xvfb-run wineconsole --backend=curses cmd /c "python-3.9.9-amd64.exe /quiet InstallAllUsers=1 PrependPath=1 Include_test=0" - - # 等待安装完成 - sleep 15 - - # 验证安装进程 - echo "Installation completed, checking..." + + # 直接用 wine 运行 + xvfb-run -a wine python-3.9.9-amd64.exe /quiet InstallAllUsers=1 PrependPath=1 Include_test=0 + + # 等待安装 + sleep 20 # 步骤4:更彻底地查找 Python - name: Find and verify Python