Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(desktop): keep Linux AppImage filename stable across updates #9946

ClosedImBIOS(GitHub profile, opens in a new tab)wants to merge 1 commit intomain fromrefs/pull/9946/headopened View on GitHub

Every release ships a differently-named AppImage (T3-Code-<version>-<arch>.AppImage), orphaning dock pins, .desktop entries, shortcuts, and file associations on each update — and leaving deleted-but-running processes behind to wedge the next launch's SingletonLock.

This sets a Linux-only artifactName without the version (T3-Code-${arch}.AppImage, T3-Code-Nightly-${arch}.AppImage for nightlies since both channels can live in ~/Applications). Follows the recommended practice from electron-userland/electron-builder#5810 (omit the version from the auto-updating artifact itself, like the mac .app; the versioned dmg/nsis names are untouched), so electron-updater replaces one stable file in place.

Fixes #9945. Tests: new case asserting both channel names; full build-desktop-artifact suite (69 tests) green, lint/fmt clean.

Built and verified with OpenCode + Muse Spark.


Note

Low Risk Linux packaging filename only; no runtime auth or data-path changes. Main risk is updater or release consumers expecting versioned Linux artifact names.

Overview Linux AppImage builds now use version-free output names so auto-updates replace the same file instead of shipping a new filename every release.

resolveLinuxArtifactName picks T3-Code-${arch}.${ext} for stable releases and T3-Code-Nightly-${arch}.${ext} for nightly builds (so both channels can coexist). The Linux electron-builder config sets linux.artifactName from that helper; macOS/Windows default versioned naming is unchanged.

A unit test locks in both channel patterns. This is meant to keep dock pins, .desktop entries, shortcuts, and file associations valid across updates and avoid orphaned AppImages blocking the next launch.

Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 05f38d6cb4eb99d50237ed71ccb90ac0c1f37690. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).

Note

Fix Linux AppImage filename to stay stable across updates

  • Adds resolveLinuxArtifactName in build-desktop-artifact.ts to return version-free artifact name templates: one for stable, one for nightly
  • Wires the resolver into createBuildConfig via electron-builder's artifactName so Linux builds emit channel-specific filenames without the build version
  • Adds tests in build-desktop-artifact.test.ts covering both stable and nightly inputs
  • Risk: Linux artifact filenames now drop the version string; any existing tooling or update flows that parse the version from the filename will need to read it elsewhere
📊 Macroscope summarized 05f38d6. 1 file reviewed, 1 issue evaluated, 0 issues filtered, 1 comment posted

🗂️ Filtered Issues

    1. github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:unvouched

    2. @@ -2668,3 +2680,6 @@
      26682680 if (platform === "linux") {
      26692681 buildConfig.linux = {
      26702682 target: [target],
      2683+ // Stable filename without the version: AppImages update in place and a
      2684+ // versioned name orphans dock pins and .desktop entries every release.
      2685+ artifactName: resolveLinuxArtifactName(version),
      macroscopeapp[bot](GitHub profile, opens in a new tab)commented

      🟠 High scripts/build-desktop-artifact.ts:2685

      The Linux build now publishes T3-Code-${arch}.${ext} (or T3-Code-Nightly-${arch}.${ext}), so the AUR release workflow and PKGBUILDs still requesting T3-Code-${version}-x86_64.AppImage fail to find every release asset and AUR installs fetch nonexistent URLs. Update packaging/aur/scripts/release.sh and both PKGBUILDs to use the new stable and nightly artifact names.

      🤖 Copy this AI Prompt to have your agent fix this:
      In file @scripts/build-desktop-artifact.ts around line 2685:
      
      The Linux build now publishes `T3-Code-${arch}.${ext}` (or `T3-Code-Nightly-${arch}.${ext}`), so the AUR release workflow and PKGBUILDs still requesting `T3-Code-${version}-x86_64.AppImage` fail to find every release asset and AUR installs fetch nonexistent URLs. Update `packaging/aur/scripts/release.sh` and both PKGBUILDs to use the new stable and nightly artifact names.
    3. Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

      Fix All in Cursor ❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the [Cursor dashboard](https://www.cursor.com/dashboard/bugbot). Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 05f38d6cb4eb99d50237ed71ccb90ac0c1f37690. Configure [here](https://www.cursor.com/dashboard/bugbot).
      @@ -2562,3 +2562,14 @@
      25622562 : (desktopPackageJson.productName ?? "T3 Code");
      25632563 }
      25642564
      2565+// Linux AppImages auto-update in place, so the artifact filename must not
      2566+// contain the version: electron-updater keeps the existing file when the
      2567+// published name carries no version, and a stable path keeps dock pins,
      2568+// .desktop entries, shortcuts, and file associations working across updates
      2569+// (electron-userland/electron-builder#5810). Nightly and stable need distinct
      2570+// names because both can live side by side in ~/Applications.
      2571+export function resolveLinuxArtifactName(version: string): string {
      2572+ return resolveDesktopUpdateChannel(version) === "nightly"
      2573+ ? "T3-Code-Nightly-${arch}.${ext}"
      2574+ : "T3-Code-${arch}.${ext}";
      2575+}

      AUR still expects versioned AppImage

      Medium Severity

      The new unversioned Linux artifactName no longer matches the AppImage assets that first-party AUR packaging downloads from GitHub Releases. release.sh and both PKGBUILDs still construct T3-Code-<version>-x86_64.AppImage, so the next AUR publish fails and Arch users stop receiving updates.

      Additional Locations (1)
      Fix in Cursor Fix in Web
      Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 05f38d6cb4eb99d50237ed71ccb90ac0c1f37690. Configure [here](https://www.cursor.com/dashboard/bugbot).
    4. Approvability

      Verdict: Not approved

      Macroscope's review found this PR not approvable — The PR changes the production Linux AppImage filename, but the AUR release script and both PKGBUILDs still request the old versioned assets. Coordinated packaging updates are needed to prevent AUR publishing and Arch installation failures.

      Not approved because:

      • 1 blocking correctness issue found at or above your repo's Minimum Blocking Severity
      Adjust the Minimum Blocking Severity for this repo — including turning it Off — in [Settings](https://app.macroscope.com/pingdotgg/settings#Repos). You can add or adjust custom eligibility rules. [Learn more](https://docs.macroscope.com/approvability#example-custom-eligibility-rules).
    5. juliusmarminge closed this

    6. Closing as part of the open-PR backlog sweep (wave 3).

      Reason: Duplicate of more complete open AppImage-name fix #8983 Related: #8983

      Reopen if this is still wanted and you’re willing to rebase onto current main.

Sign in to join this conversation.