Repository navigation
feat(macos): the app updates itself from GitHub releases - #4
Merged
Merged
Conversation
Checks the latest release at launch and every six hours, announces a newer one once (notification with an Update button, plus an entry at the top of the tray menu), and on a click downloads the release zip, verifies bundle id, version and signature, swaps the bundle in place and relaunches. Check for Updates… in the app menu asks right away. The relaunch starts the new copy as a second instance with the pid it replaces: a helper waiting for the old one to exit is killed along with the app, and NSRunningApplication only sees the exit from the run loop. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
- show the update notification even while catchbox is in front, and ask for notification permission for it when mail notifications are off - a skipped version stays out of the tray until a later one - keep 'installing' set after the swap, so the tray never offers it twice - one offer at a time; Check for Updates during an install says so - wait for the replaced copy off the main thread, and never hand over to it - remove the downloaded zip; only download from this repo's releases - a pre-release is offered its final release; no checks without a version - README no longer implies the signature proves who built the app Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
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
releases/latestat launch and every 6 hours. A newer release is announced once per version: a notification with an Update button, plus an entry at the top of the tray menu. catchbox → Check for Updates… asks right away.Catchbox-<version>.zipfrom the release, unpacks it next to the app (same volume, so the swap is a rename), checks bundle id + version +codesign --verify --deep --strict, swaps the bundle in place and relaunches. Skip This Version silences it until the next one.--replacing <pid>and waits for the old one. A helper shell that waits for the exit gets killed along with the app, andNSRunningApplicationonly learns of the exit from the run loop, so the replaced pid is excluded explicitly.CATCHBOX_UPDATE_FEEDpoints the check at your own release JSON, to test an update without publishing one.Test plan
make -C macos test: version comparison, release decoding, picking the right zipmake -C macos bundle: universal release buildNote: after a self-update the Homebrew cask still records the old version, which is harmless.
brew upgradereinstalls the same release.🤖 Generated with Claude Code