From 7f73186893e9738d0e3b91e1660cc8e8c95a70a8 Mon Sep 17 00:00:00 2001 From: Cody Ray Hoeft Date: Fri, 21 Aug 2026 09:47:41 -0700 Subject: [PATCH] fix(desktop): find linuxbrew node for the WSL backend The remote node resolver repairs PATH when a login shell does not expose node, but its fallback list only covered macOS Homebrew (/opt/homebrew/bin, /usr/local/bin). Homebrew on Linux installs to /home/linuxbrew/.linuxbrew/bin, which brew shellenv typically adds only in .bashrc, so login shells - and therefore the WSL backend probe and SSH remotes - reported node as missing even when a satisfying version was installed. Co-Authored-By: Claude Fable 5 --- packages/ssh/src/tunnel.test.ts | 1 + packages/ssh/src/tunnel.ts | 1 + 2 files changed, 2 insertions(+) diff --git a/packages/ssh/src/tunnel.test.ts b/packages/ssh/src/tunnel.test.ts index 461509ea0ad2..e51c8e392e65 100644 --- a/packages/ssh/src/tunnel.test.ts +++ b/packages/ssh/src/tunnel.test.ts @@ -116,6 +116,7 @@ describe("ssh tunnel scripts", () => { assert.include(script, "remote_node_satisfies_engine()"); assert.include(script, "function satisfiesSemverRange"); assert.include(script, "satisfiesSemverRange(rawVersion, range)"); + assert.include(script, 'prepend_path_if_dir "/home/linuxbrew/.linuxbrew/bin"'); assert.include(script, 'prepend_path_if_dir "$VOLTA_HOME/bin"'); assert.include(script, 'prepend_path_if_dir "$HOME/.asdf/shims"'); assert.include(script, 'prepend_path_if_dir "$HOME/.local/share/mise/shims"'); diff --git a/packages/ssh/src/tunnel.ts b/packages/ssh/src/tunnel.ts index 12ab0027803c..42fe971a7718 100644 --- a/packages/ssh/src/tunnel.ts +++ b/packages/ssh/src/tunnel.ts @@ -345,6 +345,7 @@ ensure_remote_node_path() { prepend_path_if_dir "$HOME/.local/bin" prepend_path_if_dir "$HOME/bin" prepend_path_if_dir "/opt/homebrew/bin" + prepend_path_if_dir "/home/linuxbrew/.linuxbrew/bin" prepend_path_if_dir "/usr/local/bin" prepend_path_if_dir "/usr/bin" prepend_path_if_dir "/bin"