我有PyCharm,我正在寻找git.exe来设置它与我的repo。

git.exe的路径是什么?


当前回答

我使用的是Windows 10, Pycharm 2016.1.2,这里是我找到Github.exe的路径:(请注意,粗体部分是变量,你应该用适用的值替换它…)

C: \用户* *萨尔曼·* * \ AppData \ Local的GitHub上的git PortableGit_c2ba306e536fdf878271f7fe636a147ff37326ad \ bin \ . exe

其他回答

首先,你应该在你的电脑上安装github; 其次,你可以下载工具“Everything”; 第三,打开工具everything,输入git.exe,然后你会找到位置并将位置复制到PyCharm,然后测试,你会成功看到!

如果你已经安装了基于powershell的git,你可以使用Get-Command对象来查找git:

Get-Command git.exe | Select-Object -ExpandProperty Definition

我在

C:\Users\~\AppData\Local\GitHub\PortableGit_<some_identifier>\mingw32\libexec\git-core\

我很惊讶地看到没有人提到使用——execc -path开关。

git - exec-path C:\Program Files\Git\ mingw64 / libexec / git-core

我希望这能帮助到一些人。

如果你安装了Visual Studio 2022, git.exe位于这里:

C:\Program Files\Microsoft Visual Studio\2022\Professional\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer\Git\mingw32\bin