Skip to content

Commit 021db9c

Browse files
HanFengRuYueclaude
andcommitted
chore: 将程序版本提升至 2.0
将版本前缀从 1.9 更新为 2.0,涉及 build.ps1、CI 工作流和文档。 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 689e0d2 commit 021db9c

4 files changed

Lines changed: 6 additions & 6 deletions

File tree

.github/workflows/build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ jobs:
5757
shell: pwsh
5858
run: |
5959
$v = '${{ inputs.build_version }}'
60-
if (-not $v) { $v = "1.9.$(Get-Date -Format 'yyyyMMddHHmm')" }
60+
if (-not $v) { $v = "2.0.$(Get-Date -Format 'yyyyMMddHHmm')" }
6161
$prefix = $v.Split('.')[0..1] -join '.'
6262
"build_version=$v" | Out-File -FilePath $env:GITHUB_OUTPUT -Append
6363
"version_prefix=$prefix" | Out-File -FilePath $env:GITHUB_OUTPUT -Append
@@ -580,7 +580,7 @@ jobs:
580580
$installerProject = "Installer/Installer.wixproj"
581581
582582
# Generate MSI version from build version
583-
# Build version format: 1.6.YYYYMMDDHHmm
583+
# Build version format: 2.0.YYYYMMDDHHmm
584584
# MSI constraints: major < 256, minor < 256, build < 65536
585585
$parts = "${{ steps.ver.outputs.build_version }}".Split('.')
586586
$timestamp = $parts[2] # YYYYMMDDHHmm

.github/workflows/dep-check.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ jobs:
9191
9292
FORCE="${{ inputs.force_build }}"
9393
if [ -n "$CHANGED" ] || [ "$FORCE" = "true" ]; then
94-
BUILD_VER="1.9.$(date -u +%Y%m%d%H%M)"
94+
BUILD_VER="2.0.$(date -u +%Y%m%d%H%M)"
9595
VER_PREFIX="v$(echo "$BUILD_VER" | cut -d. -f1,2)"
9696
RELEASE_TAG="auto-${BUILD_VER}"
9797

CLAUDE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ cd XUnityToolkit-Vue && npx vue-tsc --noEmit
142142

143143
- `dotnet build` auto-runs frontend; skip with `-p:SkipFrontendBuild=true`
144144
- `build.ps1`: downloads bundled assets → extracts XUnity reference DLLs → updates classdata.tpk (requires `gh` CLI) → frontend → TranslatorEndpoint → publish to `Release/win-x64/`; `-SkipDownload` skips all download/extraction steps; cleanup: remove `web.config`, `*.pdb`, `*.staticwebassets.endpoints.json`
145-
- **Versioning:** `build.ps1` auto-generates `1.9.{YYYYMMDDHHmm}` (CI uses `1.9.` prefix) via `-p:InformationalVersion`; **must use `InformationalVersion` not `Version`**`Version` sets `AssemblyVersion` (UInt16 max 65535) which overflows with timestamp
145+
- **Versioning:** `build.ps1` auto-generates `2.0.{YYYYMMDDHHmm}` (CI uses `2.0.` prefix) via `-p:InformationalVersion`; **must use `InformationalVersion` not `Version`**`Version` sets `AssemblyVersion` (UInt16 max 65535) which overflows with timestamp
146146
- **Multi-file publishing:** `PublishSingleFile` removed; `ExcludeFromSingleFile` target removed; LibCpp2IL.dll works naturally in multi-file mode
147147
- **Satellite assemblies:** `SatelliteResourceLanguages=en` strips all language folders (cs/de/fr/ja/ko/etc.) from publish output; WinForms satellite resources are unused (UI is Vue, native dialogs use OS localization)
148148
- **Updater:** `Updater/Updater.csproj` (net10.0, PublishAot); win-x64 only; `--data-dir` CLI arg directs log/backup paths to `paths.Root`

build.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,8 +163,8 @@ $EndpointProject = Join-Path $ProjectRoot 'TranslatorEndpoint\TranslatorEndpoint
163163
$rid = 'win-x64'
164164
$hasEndpoint = Test-Path $EndpointProject
165165

166-
# Generate version: 1.9.{YYYYMMDDHHmm}
167-
$BuildVersion = "1.9.$(Get-Date -Format 'yyyyMMddHHmm')"
166+
# Generate version: 2.0.{YYYYMMDDHHmm}
167+
$BuildVersion = "2.0.$(Get-Date -Format 'yyyyMMddHHmm')"
168168
$VersionPrefix = ($BuildVersion -split '\.')[0..1] -join '.'
169169

170170
# Generate MSI-compatible version: {(YYYY-2024)*12+MM}.{DD}.{HH*60+mm}

0 commit comments

Comments
 (0)