VS Code提示未找到Git,如何配置git.path

2022年12月22日学习笔记评论43,060字数 322阅读1分4秒阅读模式

R_22-12-22-11-40-51_80

使用VS Code 提示 '未找到Git.请安装Git,或在“git.path”设置中配置'

首先请确保已经安装git。

确保安装后,还出现这个提示,肯定是因为没有配置git安装目录。

打开VS Code的setting.json,添加下面这段即可:

	// Is git enabled
    "git.enabled": true,

    // Path to the git executable
    "git.path": "H:\\Program Files\\Git\\bin\\git.exe",
    "git.defaultCloneDirectory": "H:\\Documents\\Github\\"

找不到设置的,可以参考下图:

R_22-12-22-11-37-15_80

配置完成,重启下VS Code即可使用Git了。

匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定