原始回答(2015年11月初)
首先,GitHub上可获得的Windows版本最新Git。
我总是使用压缩包的形式(解压到任意位置,并将其添加到PATH
中)。
但是,如果你选择了exe
安装程序,那就意味着它已经安装在C:\Program Files\Git
中。
不过,正如我在这里提到的, Git也包含在GitHub桌面应用程序的安装路径中(%USERPROFILE%\AppData\Local\GitHub\PORTAB~1\bin
)
理论上,你可以通过一个目录JUNCTION来替换文件夹PORTAB~1的确切值:
cd %USERPROFILE%\AppData\Local\GitHub
dir # take note of the exact name of PORTABLEGIT folder: <PORTAB...>
move <PORTAB...> old_PORTABLEGIT
mklink /J <PORTAB...> "C:\Program Files\Git"
C:\Users\vonc\AppData\Local\GitHub\PortableGit_c2ba306e536fdf878271f7fe636a147ff37326ad\bin
C:\Users\vonc\AppData\Local\GitHub\PortableGit_c2b...\etc\gitconfig
[http]
sslcainfo = /bin/curl-ca-bundle-ghfw.crt
[credential]
helper = !github --credentials
[filter "ghcleansmudge"]
clean = cat
smudge = cat
.0
结尾的GIT版本--请在此处查看屏幕截图:https://imgur.com/SZRDZrz - Fuhrmanator您可以在这里找到Windows Git安装程序:http://www.git-scm.com/
为了获得最佳效果,我建议卸载Github桌面版,安装Git(从上面链接下载),然后重新安装Github客户端。