andy-5 / wslgit

Use Git installed in Bash on Windows/Windows Subsystem for Linux (WSL) from Windows and Visual Studio Code (VSCode)
MIT License
1.18k stars 59 forks source link

Translate network share WLS2 paths into linux paths #106

Open Niksac opened 4 years ago

Niksac commented 4 years ago

Hi,

i'm experimenting with WSL2. I would love to make use of the greatly enhanced performance with moving my projects into the linux containers.

I use the WSL extension in VS Code and can work like normal. Unfortunately my git tool (Gitkraken) understandably is slow when opening via the network shares.

If wslgit could translate paths like \\wsl$\Ubuntu\home\nik\dev\booking into /home/nik/dev/booking and use the git within the container this would probably speed things up.

Has anyone tried this? I am aware of the possibility to run GitKraken within the container with XForwarding but this is slow too for me.

carlolars commented 4 years ago

If I remember correctly GitKraken use a built-in gitlib so wslgit unfortunately cannot help.

Niksac commented 4 years ago

That's true. I found that out too and translating the paths would only help with tools like Fork and of course command line git work.

rfgamaral commented 3 years ago

I use SmartGit instead of GitKraken, which allows me to pick the git executable I want to use, so I second this feature request.

If wslgit could translate network paths like \\wsl$\<DISTRO_NAME>\<PATH> to /<PATH>, this would allow us to take advantage of WSL2 performance (by moving the projects into the WSL2 environment) and still use GUI tools like SmartGit or Fork without too much of an impact on performance.

@andy-5 What do you think of this? Let me know if I can help with anything :)

carlolars commented 3 years ago

I use SmartGit instead of GitKraken, which allows me to pick the git executable I want to use, so I second this feature request.

If wslgit could translate network paths like \\wsl$\<DISTRO_NAME>\<PATH> to /<PATH>, this would allow us to take advantage of WSL2 performance (by moving the projects into the WSL2 environment) and still use GUI tools like SmartGit or Fork without too much of an impact on performance.

wslgit-v1.0.1 should be able to do that. I've been using Fork and wslgit daily at work and home to access repositories in the WLS2 (Ubuntu-20.04) filesystem via \\wsl$\Ubuntu-20.04\... since WSL2 was officially released, and it works really well.

rfgamaral commented 3 years ago

Well, if the current wslgit version is already translating those paths correctly then I guess this is no longer a viable solution for me because the Git interation is very slow. Not ideal, but I'm currently using the Linux version of SmartGit through X410, until something better comes along.