fix(installer): derive macOS pkg version from ui/package.json#57
Open
Relevant47 wants to merge 1 commit into
Open
fix(installer): derive macOS pkg version from ui/package.json#57Relevant47 wants to merge 1 commit into
Relevant47 wants to merge 1 commit into
Conversation
The build script hardcoded VERSION="1.0.0", so every manual macOS PKG produced FocusLock-1.0.0.pkg with stale pkgutil metadata regardless of the actual release version. Fixes #56
✅ Deploy Preview for focuslock-app ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
installer/macos/build-pkg.shhardcodedVERSION="1.0.0", so every manual macOS PKG was namedFocusLock-1.0.0.pkgand recordedversion: 1.0.0inpkgutil --pkg-info com.focuslock.daemonregardless of the actual release. Now derived fromui/package.json(single source of truth perCLAUDE.md), with an optional positional override (./build-pkg.sh 1.2.3) for the rare case a builder needs to stamp a different version.Files changed
installer/macos/build-pkg.sh— replace hardcodedVERSION="1.0.0"with${1:-$(node -p "require('$REPO_ROOT/ui/package.json').version")}; reorder soSCRIPT_DIR/REPO_ROOTare computed beforeVERSION. Updated header comment.Smoke-tested locally — the default expression reads
1.1.4from the currentui/package.json; passing1.9.9as$1overrides to that value.Fixes #56
Risk tier
Trivial / single-file → normal PR, ready for review.
nodeis already a hard dependency for buildingui/, which the script's preconditions already assume (it checks$UI_APPexists fromnpm run tauri build).pkgutilmetadata match the real release.Option NOT taken
The issue suggests a follow-up to wire
build-pkg.shintorelease.yml. That's intentionally out of scope here — separate workflow change, separate review.🤖 Generated with Claude Code
Generated by Claude Code