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

Adding remote project folders could be easier #76

Open
looeee opened this issue Nov 25, 2021 · 6 comments
Open

Adding remote project folders could be easier #76

looeee opened this issue Nov 25, 2021 · 6 comments

Comments

@looeee
Copy link

looeee commented Nov 25, 2021

I'm working in Windows with WSL. If I have a Vscode session open in WSL and I try to add the current folder as a Folder project it will give me something like this:

\\wsl$\Ubuntu\home\lewy\dev\projectFolder

However, if I use the dashboard to open this project it will open in a standard Windows VSCode session which is not what I want.

I need the URL to look like this:

vscode-remote://wsl+Ubuntu/home/lewy/dev/three.js

The only way I have found to add this URL is to create an SSH project and copy in the in vscode-remote://wsl+Ubuntu URL.

I have two suggestions for making this easier:

  1. allow me to manually edit the path of a Folder project. At the moment if I try to edit the path it just takes me back to the Windows open folder menu. But if I could just hit edit and change the start of the path to ``vscode-remote...` it would make things easier.
  2. Rename SSH Target to Remote Project since it's not only SSH folders that can be added here.

Beyond those it would be great to recognize when VSCode is open in a remote session and automatically prepend the correct data to the path. The Project Manager extension currently does this.

@Kruemelkatze
Copy link
Owner

Thanks for the remarks! I need to have a closer look on that as I've never really worked with WSL or VSCode remote sessions myself.

Beyond those it would be great to recognize when VSCode is open in a remote session and automatically prepend the correct data to the path. The Project Manager extension currently does this.

What data is relevant here? vscode-remote://wsl+Ubuntu?

@looeee
Copy link
Author

looeee commented Nov 25, 2021

What data is relevant here? vscode-remote://wsl+Ubuntu?

I'm not sure. Maybe you can assume a path starting with \\wsl$ is a wsl project and that you can just do a replace with \\wsl$\xxx\ -> vscode-remote://wsl+xxx/?

Or maybe look at the code for Project Manager and see what they do?

@urbgimtam
Copy link

Same issue here.
As all my projects are in WSL2, it becomes quite unusable.

@David-Kyrat
Copy link

Same for me, I really need to use every day wsl2 for my projects and University work and i cannot use this extension anymore because of this. It'd be really cool to have a feature "WSL folder" or "remote proejct/window" etc.

@Kruemelkatze
Copy link
Owner

Sorry fot the late response! With the latest update 2.6.0, I came back to this issue and included this functionality. However, I was still not able to quite understand this use-case, as I'm not using WSL. Sorry about that. 🤷‍♂️

I based the function on your comments. You should be able to enter \\wsl$\xxx\with the new Enter Manually option for the project path. This is then changed to vscode-remote://wsl+xxx/. This behaviour can also be toggled with a setting in case something doesn't work:

image

If it doesn't work, feel free to address this issue again! :)

@diegocrivelaro
Copy link

Should it stay that way?
image

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

5 participants