Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Need a way to override the readapt binary location #23

Open
xeger opened this issue Jul 4, 2022 · 0 comments
Open

Need a way to override the readapt binary location #23

xeger opened this issue Jul 4, 2022 · 0 comments

Comments

@xeger
Copy link

xeger commented Jul 4, 2022

I have a complex monorepo with several different languages - including several concurrent versions of Ruby itself, using asdf as a version manager - and dozens of processes/packages.

I'm using a single multi-root VS Code workspace in this monorepo, and generally speaking, I love it.

Problem: there is no single Ruby app/gem in my workspace! The Ruby Debug extension gets very confused about what the working directory should be, and where my bundle is, and other details.

For Node debugging, I handily solved the problem by introducing a wrapper script that establishes a suitable CWD before invoking node. Then, I created a launch configuration like so:

"type": "node",
"runtimeExecutable": "${fileWorkspaceFolder}/.vscode/wrappers/yarn"

I need a similar escape hatch for Ruby Debug. Your useBundler option is a great start, but it just can't deal with the enormous level of complexity in my project. (I also need to ensure that the right Ruby binary is invoked, too - being that I have several Ruby versions in use).

Solutions Tried So Far

I looked at your source and found out that you support a debugger option that I should be able to use to point to my bash wrapper script. When I try this, my wrapper is never invoked and VS Code tells me:

Debugger exited without connecting (exit code 1)

I looked into ruby-spawn to see if it was the culprit; it is my likeliest suspect and if I have the time, I'll debug this extension and see what the heck is being spawned.

@xeger xeger changed the title Need a ` Need a way to override the readapt binary location Jul 4, 2022
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

No branches or pull requests

1 participant