-
Notifications
You must be signed in to change notification settings - Fork 23
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
Can't start solargraph gem through WSL #80
Comments
After diving into the code (I have basic understanding of js/ts), it seems that the problem is Nevertheless I found a workaround (use a
I still have problems solargraph not being able to follow correctly requires (and almost everyone outside the stdlib says it doesn't exist; but that's a different problem) |
Thanks for figuring that out. That's the most success I've heard from anyone trying to connect VS Code in Windows to Solargraph in WSL. If the unfound requires are gems, you might be missing YARD documentation. There's an option to |
For anyone who's looking for clearer instructions for the work around by @pablox-cl #80 (comment) using rvm and WSL1:
|
@mtam2 Where do you run |
@OrkunSA Run |
@mtam2 I just did and I got |
Yes, create a file like normal and paste
Save the file somewhere simple and copy the file's location. Now open VSCode and open the command palette (ctrl+shift+p) and search "preferences: open settings (JSON)" |
It's giving me the error below. @mtam2 |
|
Thanks so much @mtam2 u saved me a lot of time! 😄 But on Ubuntu, solargraph is in
vscode says
And when i leave |
In your case using asdf, you must reshim your ruby. asdf reshim ruby After this, asdf will provide link to gem, then restart vscode. |
There is a simpler solution than creating batch files that may not work depending on your setup. Install Remote - WSL extension and start VS Code from your WSL with |
not working for me |
@liciniomendes method works fine. Make sure you check your extensions because they will need to be installed again. You will see errors like below. Just press the "Install in WSL" button next to each extension you want to install. I had to do this for my Ruby plugins. And here's an image showing it working: |
I can ran solargraph when installed trough rubyinstaller, but I can't run it trough the wsl. Through the terminal (wsl) I'm using rbenv:
If just let
solargraph
as the command path inside VSCode, it ran inside the "rubyinstaller" version:If I try to set the:
I get:
Which, kind of makes sense since VSCode doesn't run from inside wsl.
Trough the windows command prompt is possible to run file from the wsl:
or...
Though, trying both
commandPath
, results in strange errors:Maybe it's possible to run solargraph trough bash trough the plugin internals?
The text was updated successfully, but these errors were encountered: