AX-1579 - Robust support for multiple shells#35
Closed
MatanEden1 wants to merge 2 commits into
Closed
Conversation
$SHELL only reports the user's OS login shell, not the shell Cursor actually uses to launch hooks/MCP servers, so a single-file guess can silently miss (confirmed: bash and zsh never source each other's rc files, in login or non-login mode). Persist to every common startup file instead, and verify afterward via the existing 4a/troubleshooting checks rather than assuming the write was sourced. Bump plugin version 0.5.1 -> 0.5.2.
…using-bash # Conflicts: # .cursor-plugin/marketplace.json # plugins/jfrog/.cursor-plugin/plugin.json
Collaborator
Author
|
Superseding with a PR from a branch on jfrog/cursor-plugin directly (instead of a fork branch) — see replacement PR. |
3 tasks
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.
What
Follow-up to #15. That PR made secret-persistence guidance shell-aware by detecting
$SHELLand picking the matching rc file. This PR removes the single-file guess entirely.Why
$SHELLreports the user's OS-configured login shell, not necessarily the shell Cursor actually uses to launch hooks/MCP servers. A user reported$SHELL=/bin/zsh(so the export went into~/.zshrc), but Cursor's hook/MCP-launch process ran under bash, which never sources~/.zshrc— the var was silently invisible to it.Verified empirically (not just from memory) that:
.zshrc, and zsh never sources.bashrc/.bash_profile— in login or non-login mode.So a single-file guess based on
$SHELLcan miss regardless of how carefully the shell is detected.Changes
plugins/jfrog/templates/jfrog-mcp-management.md: secret-persistence guidance now tells the agent to write the export to every common startup file (~/.zshrc,~/.bashrc,~/.bash_profile, fish config) instead of picking one, and to verify afterward via the existing 4a / "401/403 with${env:VAR}" troubleshooting steps rather than assuming the write took effect.0.5.1→0.5.2(plugin.json+marketplace.json).Test plan
node ./scripts/validate-template.mjspassesHOME/ZDOTDIRshell tests that bash/zsh don't cross-source rc files and don't source them non-interactively