From ad98eb18dc342348488ded1e7332a53e7f409ba0 Mon Sep 17 00:00:00 2001 From: cnb Date: Sun, 30 Aug 2026 15:50:35 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20=E5=8F=91=E5=B8=83=20v1.0.0=E2=80=94?= =?UTF-8?q?=E2=80=94=E5=BD=92=E6=A1=A3=E5=8F=98=E6=9B=B4=E6=97=A5=E5=BF=97?= =?UTF-8?q?=E5=B9=B6=E6=B7=BB=E5=8A=A0=E5=8F=91=E5=B8=83=E6=89=93=E5=8C=85?= =?UTF-8?q?/=E9=AA=8C=E8=AF=81=E8=84=9A=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 2 ++ scripts/make-release-packages.ps1 | 11 +++++++++++ scripts/verify-publish.ps1 | 14 ++++++++++++++ 3 files changed, 27 insertions(+) create mode 100644 scripts/make-release-packages.ps1 create mode 100644 scripts/verify-publish.ps1 diff --git a/CHANGELOG.md b/CHANGELOG.md index 5858bfb..d3cd4cf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,8 @@ ## [Unreleased] +## [1.0.0] - 2026-08-30 + ### Added - 首次实现“一键运行”完整功能(v1.0.0 基线): diff --git a/scripts/make-release-packages.ps1 b/scripts/make-release-packages.ps1 new file mode 100644 index 0000000..7ac2161 --- /dev/null +++ b/scripts/make-release-packages.ps1 @@ -0,0 +1,11 @@ +# 生成发布压缩包:框架依赖版 + 自包含版 +$ErrorActionPreference = 'Stop' +$root = Split-Path -Parent $PSScriptRoot +$publish = Join-Path $root 'publish' + +Compress-Archive -Path (Join-Path $publish 'win-x64-fdd/*') -DestinationPath (Join-Path $publish 'OneClickRun-1.0.0-win-x64-fdd.zip') -Force +Compress-Archive -Path (Join-Path $publish 'win-x64-sc/*') -DestinationPath (Join-Path $publish 'OneClickRun-1.0.0-win-x64-sc.zip') -Force + +Get-ChildItem (Join-Path $publish '*.zip') | + Select-Object Name, @{n='MB';e={[math]::Round($_.Length/1MB,1)}}, @{n='Time';e={$_.LastWriteTime}} | + Format-Table -AutoSize diff --git a/scripts/verify-publish.ps1 b/scripts/verify-publish.ps1 new file mode 100644 index 0000000..2f99ada --- /dev/null +++ b/scripts/verify-publish.ps1 @@ -0,0 +1,14 @@ +# 发布产物冒烟:--snapshot 模式显示轮盘、导出 PNG 后自动退出 +$ErrorActionPreference = 'Stop' +$exe = $args[0] +$outPng = $args[1] +if (-not (Test-Path $exe)) { throw "未找到: $exe" } +Remove-Item $outPng -ErrorAction SilentlyContinue + +$v = (Get-Item $exe).VersionInfo +Write-Output ("版本信息: FileVersion={0} ProductVersion={1}" -f $v.FileVersion, $v.ProductVersion) + +$p = Start-Process -FilePath $exe -ArgumentList @('--snapshot', $outPng) -PassThru +if (-not $p.WaitForExit(15000)) { Stop-Process -Id $p.Id -Force; throw '快照模式 15 秒未退出' } +Write-Output "退出码: $($p.ExitCode)" +Write-Output "快照已生成: $(Test-Path $outPng) ($(if (Test-Path $outPng) { (Get-Item $outPng).Length } else { 0 }) bytes)"