feat(ENG-14145): self-update command and background update check - #419
Draft
tigh-latte wants to merge 8 commits into
Draft
tigh-latte wants to merge 8 commits into
tigh-latte wants to merge 8 commits into
Conversation
to allow for a check when running in json or something, and a notification to be suppressed until later in a future run
- fix windows update - fix in-place downloads
Previous implementation of the in-place update replaced the whole cloudsmith install dir with the exploded update dir, which would delete any user files in that dir. Instead, we read the manifest and target files for replacement.
remove config via env var for the manifest url
The background check was always checking linux-x86_64-gnu regardless of platform/arch. We will now probe for the latest version of the host's own platform.
The TestMainUpdateNotice tests rely on the update check actually running, but update_check_disabled() short-circuits when $CI is set (as it is in GitHub Actions). Clear CI and CLOUDSMITH_NO_UPDATE_CHECK in the state_file fixture so the notice logic under test runs regardless of environment.
tigh-latte
force-pushed
the
tigh/feat/update
branch
from
September 17, 2026 10:08
15918d2 to
0a1bb11
Compare
Address PR review: surface a 'See what's changed' link so users know what they gain by upgrading. installation.changelog_url() points at the target version's GitHub release page (tagged v<version>), which renders that version's changelog; it falls back to the releases list when no version is known. Wired into the background update notice and both the package-managed and Windows manual-update paths of `cloudsmith update` (text + JSON, via a new changelog_url field).
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
Adds a
cloudsmith updatecommand for self-updating standalone binary installs, plus a non-intrusive background check that notifies users when a newer version is available.Changes
updatecommand (cli/commands/update.py): self-updates the standalone binary installation. Reads the release manifest, downloads and replaces target files in place (per-file replace rather than swapping the whole install dir, so user files in the install dir are preserved). Handles Windows update quirks.core/update_check.py): probes for the latest version of the host's own platform/arch (previously always probedlinux-x86_64-gnu). Uses a non-configurable manifest URL. Tracks a second "last notified" timestamp so a notification can be suppressed until a later run (e.g. when running in JSON mode).core/installation.py): detects how the CLI was installed to decide whether self-update applies.core/self_update.py): download/verify/replace logic.cli/config.py+data/config.ini, and wiring intomain.py/registry.py/utils.py.Tests
New unit tests for the update command, self-update engine, installation detection, background check, and main-group integration.
Notes
Tracking: ENG-14145