mirror of
https://github.com/esengine/DeepSeek-Reasonix.git
synced 2026-11-07 10:45:59 -10:00
fix(desktop): stamp the release version into the build (#2779)
A local Wails build produced an exe with a blank "File version" in its Windows
properties. wails.json's info block carried no productVersion, so the generated
versioninfo template resolved `{{.Info.ProductVersion}}` to empty and the binary
shipped with no usable file version.
Fill the info block (companyName, productVersion, copyright) and have
desktop-build.sh stamp productVersion from the tag before `wails build` —
numeric only, since a leading "v" breaks goversioninfo's fixed-version parse.
The same productVersion feeds the macOS bundle version. Verified the exe's
FileVersionRaw now reads the tag version.
Co-authored-by: reasonix <[email protected]>
This commit is contained in:
1 parent
2ad62ffa80
commit
4755e22e10
2 files changed
+9
No files matched your search
@@ -25,6 +25,12 @@ BINNAME="reasonix-desktop" # wails.json outputfilename -> linux binary name
|
||||
|
||||
cd "$ROOT/desktop"
|
||||
|
||||
# Stamp the version resource (Windows file properties, macOS CFBundleVersion) from
|
||||
# the tag. Wails reads info.productVersion from wails.json; goversioninfo needs it
|
||||
# numeric, so a leading "v" must go or the whole version block is silently dropped.
|
||||
numver="${VERSION#v}"
|
||||
node -e 'const fs=require("fs"),f="wails.json",j=JSON.parse(fs.readFileSync(f,"utf8"));j.info.productVersion=process.argv[1];fs.writeFileSync(f,JSON.stringify(j,null,2)+"\n")' "$numver"
|
||||
|
||||
# NSIS installer is Windows-only (Wails requires a single windows target for -nsis).
|
||||
build_args=(-clean -platform "$PLATFORM" -ldflags "-X main.version=$VERSION")
|
||||
[ "$os" = windows ] && build_args+=(-nsis)
|
||||
|
||||
Reference in new issue
Block a user