假如git不是安装在c盘中,用vscode打开git项目时会报Git not found. Install it or configure it using the ‘git.path’ setting并且点击左侧菜单栏的git时显示vscode git no source control providers,这是找不到git的安装路径导致的
解决办法:
- 点击“文件”->“首选项”->“设置” 搜索git.path,
- 编辑settings.json添加 “git.path”: “E:\mypath\Git\bin\git.exe"或者"git.path”:“E:/mypath/Git/bin/git.exe”,为什么是"\"和“/”呢,因为用“\”会报错啊!