Files
poli0981andClaude Opus 5.5 d50ef55369
Build / build (push) Skipped
Build / package (push) Skipped
Build / build (pull_request) Successful in 1m37s
Reusable / Qodana / Qodana (pull_request) Successful in 3m5s
Qodana / qodana (pull_request) Successful in 3m5s
Security / workflow-lint (pull_request) Successful in 6s
Reusable / Security / Rust (cargo-deny) (pull_request) Skipped
Reusable / Security / Secrets (gitleaks) (pull_request) Successful in 9s
Reusable / Security / SAST (Opengrep) (pull_request) Successful in 15s
Reusable / Security / Dependencies (osv-scanner) (pull_request) Successful in 12s
Reusable / Security / .NET (NuGetAudit) (pull_request) Successful in 40s
Security / scan (pull_request) Successful in 1m18s
Build / package (pull_request) Successful in 1m22s
docs: the R2 folder has no assets.win.json; VT_API_KEY can be user-level
vpk pack writes assets.win.json locally, but vpk upload s3 publishes only the
packages, the installer, the portable zip, releases.win.json and RELEASES
(seen on the 2.3.0 release). The VirusTotal key the 2.3.0 release used is a
user-level secret, so RELEASING.md no longer says it must be on the
repository.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-26 10:08:04 +07:00

4.7 KiB

How updates work (Velopack)

CommandForge installs and updates itself with Velopack. Updates are per-user and need no UAC.

For users

  1. Download CommandForge-win-Setup.exe and run it. It installs per-user under %LocalAppData%\CommandForge. The releases page lists every version with its notes and checksums.
  2. After that, the app checks https://releases.poli0981.dev/commandforge for newer versions — on startup if Settings → Updates → Check for updates on startup is on (the default), or when you choose More (⋯) → Check for updates or press F5.
  3. When a newer version exists, choose Download & restart. The app downloads the update (a small delta when possible), then restarts into the new version.

Versions 2.2.0 and older checked GitHub Releases. The GitHub account behind the project was suspended in November 2026, so those versions find nothing (the check ends with "No release feed was found") and can't update themselves. Install 2.3.0 or later once by hand, over the old version: settings, favorites, history, recipes and your commands stay where they are.

Good to know:

  • Closing the update dialog — including with its X button — cancels the download.
  • The app never restarts in the middle of a command: if one is running, finish or cancel it first. If you start a command while the update downloads, the restart waits; choose Download & restart again when the command is done.
  • Before applying an update, the app ends the admin session, because the elevated helper runs from the folder that Velopack replaces.
  • Errors are shown in plain words: offline or timed out, no release feed found (404), the update server refused or rate-limited the request (403/429), and a server error (5xx).

The only network connection involved is to releases.poli0981.dev (see PRIVACY.md).

How it works under the hood

  • Program.Main calls VelopackApp.Build().Run() before WPF starts, to handle the install/update/uninstall hooks.
  • The app checks for updates via new UpdateManager("https://releases.poli0981.dev/commandforge") (ProductLinks.UpdateFeed): Velopack's HTTP source reads releases.win.json there and downloads the packages it lists from the same folder. No token, no API.
  • The folder is a Cloudflare R2 bucket served through Cloudflare. The feed files (releases.win.json, RELEASES) and the stable-named installer and portable zip bypass the edge cache; every other file name carries its version and is never overwritten.
  • Download and apply are separate steps, so the app can end the admin session and check for a running command just before it restarts.
  • Auto-update works for the installed app and for the portable zip (both carry Velopack's Update.exe). A build you run from source can't update; the app detects this and says so instead of offering an update.

Release files and the delta mechanism

Each release (see RELEASING.md) puts these files under https://releases.poli0981.dev/commandforge/:

File Purpose
CommandForge-win-Setup.exe First-time installer (always the newest release)
CommandForge-win-Portable.zip The app without an installer; extract it anywhere and it updates itself in place (settings and logs still go to %AppData%\CommandForge)
CommandForge-<version>-full.nupkg Full package (fallback / first install of a version)
CommandForge-<version>-delta.nupkg Delta from the previous version (small download)
releases.win.json / RELEASES Update manifest the client reads (uploaded last)
<version>/SHA256SUMS SHA-256 of what that version ships: installer, portable zip, packages, SBOM
<version>/sbom.cdx.json CycloneDX software bill of materials

There is no directory listing: the release notes on the releases page link each file. The feed keeps the ten newest releases.

Velopack needs the previous -full.nupkg present while packing to compute a delta. The release workflow runs vpk download s3 before vpk pack, so every release after the first one on R2 produces both a -full.nupkg and a -delta.nupkg; clients on the previous version download only the delta, and the full package remains the fallback. 2.3.0, the first release on R2, had no previous version there, so it shipped only a full package.

If you ever build a release locally, run dotnet vpk download http --url https://releases.poli0981.dev/commandforge first so the prior full package is available for the delta — otherwise only a full package is produced.