-
Notifications
You must be signed in to change notification settings - Fork 15
开始打包 #158
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
开始打包 #158
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR removes the Inno Setup packaging step from the Windows build workflow, which eliminates the generation of Windows installer executables. Despite the title "开始打包" (start packaging), the change actually removes packaging functionality rather than adding it.
Changes:
- Removed the Inno Setup packaging step (27 lines) that generated Windows installer executables (.exe) for Windows builds
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| $outputZip = "zip/SecRandom-${{ matrix.platform }}-${{ github.ref_name }}-${{ matrix.arch }}-${{ matrix.pack_mode }}.zip" | ||
| Compress-Archive -Path zip_dist/SecRandom/* -DestinationPath $outputZip -Force | ||
| echo "目录模式打包完成: $outputZip" | ||
Copilot
AI
Jan 11, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The removal of the Inno Setup packaging step eliminates the ability to generate Windows installer executables (.exe files). After this change, Windows builds will only produce ZIP archives. This is a breaking change that affects the release artifacts available to end users. Consider whether this removal is intentional, and if so, update the documentation and remove the now-unused SRsetup.iss file from the repository. If Inno Setup packaging should be retained, this deletion should be reverted.
| # 使用 Inno Setup 生成 Windows 安装程序(.exe) | |
| echo "开始生成 Inno Setup 安装程序..." | |
| # 安装 Inno Setup(使用 Chocolatey,windows-latest 运行器中预装) | |
| choco install innosetup -y | |
| # 尝试定位 ISCC.exe | |
| $possibleIsccPaths = @( | |
| "C:\Program Files (x86)\Inno Setup 6\ISCC.exe", | |
| "C:\Program Files\Inno Setup 6\ISCC.exe" | |
| ) | |
| $isccPath = $possibleIsccPaths | Where-Object { Test-Path $_ } | Select-Object -First 1 | |
| if (-not $isccPath) { | |
| echo "错误:未找到 Inno Setup 编译器 ISCC.exe" | |
| Get-ChildItem "C:\Program Files" -Recurse -Filter "ISCC.exe" -ErrorAction SilentlyContinue | Select-Object -First 10 | ForEach-Object { $_.FullName } | |
| exit 1 | |
| } | |
| echo "使用 Inno Setup 编译器: $isccPath" | |
| if (-not (Test-Path "SRsetup.iss" -PathType Leaf)) { | |
| echo "错误:未找到 Inno Setup 脚本 SRsetup.iss,无法生成安装程序" | |
| exit 1 | |
| } | |
| # 可根据需要将版本号传递给 Inno Setup,比如 /DMyAppVersion | |
| $version = "${{ github.ref_name }}" | |
| & "$isccPath" "/DAppVersion=$version" "SRsetup.iss" | |
| if ($LASTEXITCODE -ne 0) { | |
| echo "错误:Inno Setup 编译失败,退出代码:$LASTEXITCODE" | |
| exit $LASTEXITCODE | |
| } | |
| # 将生成的安装程序移动到 zip 目录,便于后续上传 | |
| $installerFiles = Get-ChildItem -Path . -Filter "*.exe" -Recurse | Where-Object { $_.Name -like "SecRandom*.exe" } | |
| if (-not $installerFiles) { | |
| echo "警告:未在仓库中找到生成的 SecRandom 安装程序 exe 文件" | |
| } else { | |
| foreach ($file in $installerFiles) { | |
| echo "找到安装程序: $($file.FullName),移动到 zip 目录" | |
| Copy-Item -Path $file.FullName -Destination "zip/" -Force | |
| } | |
| } |
| Compress-Archive -Path zip_dist/SecRandom/* -DestinationPath $outputZip -Force | ||
| echo "目录模式打包完成: $outputZip" | ||
Copilot
AI
Jan 11, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR title and description say "开始打包" (start packaging), but the actual change removes the Inno Setup packaging step. This is misleading and contradicts the actual changes made. The PR description should accurately describe that this removes Windows installer generation.
开始打包