Skip to content

fix(server): repoint and adopt all owned CLI launchers after self-update - #499

Merged
shuv1337 merged 9 commits into
mainfrom
fix/cli-launcher-self-update
Nov 25, 2026
Merged

shuv1337 merged 9 commits into
mainfrom
fix/cli-launcher-self-update

Conversation

@shuv1337

Copy link
Copy Markdown
Owner

Closes #478

After the background service committed a self-update, ServiceLauncherClient.repointLaunchers only looked for a launcher literally named t3, ignored <baseDir>/bin/* and runtime/launchers, did not follow symlink-to-script forwarders (such as ~/.local/bin/{s2code,shuv2code} -> <baseDir>/bin/shuv2code), never adopted discovered launchers into runtime/launchers, and skipped Windows.

  • Discovers owned launcher candidates across runtime/launchers, <baseDir>/bin, install bin directories (S2CODE_INSTALL_BIN_DIR, SHUV2CODE_INSTALL_BIN_DIR, T3CODE_INSTALL_BIN_DIR, ~/.local/bin, Windows LOCALAPPDATA), and all PATH entries for every owned name (s2code*, shuv2code*, s2c, t3).
  • Resolves POSIX symlink chains safely (with cycle/depth guards): repoints owned target scripts in place while preserving symlink aliases, rewrites legacy symlinks directly targeting runtime/versions, and records adopted launchers in runtime/launchers.
  • Adds Windows .cmd direct and forwarder shim repointing while leaving foreign/custom launchers untouched, and aligns cli/update.ts (repointLauncher / findWindowsShim).

Built with Gemini 4 Neon via T3 Code / Antigravity.

@shuv1337
shuv1337 merged commit 27cd568 into main Nov 25, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CLI launcher stays on the old version after the service updates itself

1 participant