1

I just installed Ubuntu on Windows for Ruby on Rails development and when I create Rails project I want to open it in VS Code. So I type code . in bash to open the current folder in VS Code. But instead, it opens system32 in VS Code.

Can I even open the project from bash like that? If not, what is the correct way?

  • 1
    It probably has something to do with WSL and how it operates. When I try code . on my Linux desktop, it opens current directory as expected. Maybe try it with the full path or use code --help. There are some options which look usable for your case, like --folder-uri – marosg Feb 27 at 7:15
  • It works for me as well code . in linux desktop but in WSL no, I tried code --folder-uri but still nothing. – crodev Feb 27 at 16:56
  • I used the following guide to accomplish what you are describing: code.visualstudio.com/docs/remote/wsl – Daniel Watson May 12 at 1:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.