Repository navigation
Detect Devin Desktop's bundled CLI on macOS - #13
Merged
TheOnlyFusionCube merged 1 commit intoOct 23, 2026
Merged
Conversation
devin was only looked up on PATH, so machines with Devin Desktop but no standalone CLI install reported the CLI as missing. Resolve the binary once per process in this order: the DEVIN_COMPANION_DEVIN_BINARY override, devin on PATH, then (macOS only) the Devin Desktop app-bundle CLI, validated as an executable regular file and resolved with realpath. Setup, auth, session listing, print runs, and the stop-review-gate hook all use that one binary, and setup reports its path and source.
TheOnlyFusionCube
approved these changes
Oct 23, 2026
TheOnlyFusionCube
left a comment
Owner
There was a problem hiding this comment.
Verified macOS Desktop bundle detection and path precedence (40 passed). Clean implementation of Proposal 8.
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.
Proposal 8 in #4.
What was wrong: the plugin only looked for
devinon PATH. Devin Desktop ships the CLI inside its app bundle without putting it on PATH, so on a Desktop-only Mac/devin:setupsaid "NOT FOUND" even though a working CLI was installed.What changed
resolveDevinBinary()inlib/devin.mjs, run once per process, in this order:DEVIN_COMPANION_DEVIN_BINARY, used exactly as given. A bad value is reported by setup, never silently replaced.devinon PATH, searched with fs rather than a shell. Behavior is unchanged whendevinis on PATH./Applications/Devin.app/Contents/Resources/app/extensions/windsurf/devin/bin/devin. It's resolved withrealpathand must be an executable regular file./devin:setupshows the binary path and where it came from (env, PATH, or Devin Desktop app bundle). The "not found" guidance now mentions Devin Desktop.DEVIN_COMPANION_DESKTOP_BINARY_CANDIDATEreplaces the app-bundle path so tests can simulate Devin Desktop on any OS. It's documented as test-only.DEVIN_BINARYis no longer exported. Its only consumer, the companion, now callsgetDevinBinary().How tested
tests/binary.test.mjs, 12 tests:devin, a spawned process sees setup report the CLI as installed, andtaskinvokes the bundled binary.devinremoved from PATH.devinoff PATH: setup selected the app-bundle CLI and reported it authenticated.