Using Git in Windows Subsystem for Linux through IntelliJ

前端 未结 9 913
萌比男神i
萌比男神i 2021-01-30 11:10

I\'m trying to set Git executable in IntelliJ to be the git installed in Windows Subsystem for Linux, I tried a few different ways, but always got some sort of error. Today I in

9条回答
  •  北恋
    北恋 (楼主)
    2021-01-30 11:19

    As Gabrielizalo answered earlier, you need to use version 2020.2 and higher.

    • Go to Settings | Version Control | Git

    • Add \\wsl$\YOUR-WSL-VERSION\usr\bin\git to the Path to Git executable.

    Please note, if you are using the WLinux distribution, you need to use the name Pengwin. Even though the wsl -l command outputs the name as WLinux. Perhaps It will be fixed in future versions.

    This is how it works for me \\wsl$\Pengwin\usr\bin\git.

提交回复
热议问题