Git not found. Please install Git, or configure VS Code in the "git.path" setting to not detect the installed GIT solution summary

under win10 system

After installing Visual studio code, installed Git

But running VS Code output gives the following prompt:


solution

First, rule out the problem of unsuccessful installation of Git

Open CMD and enter the command: git

If it appears normally, the following prompts indicate that there is no problem with your Git installation

Then the solution only needs the following operations, if not, the solution will be introduced later:

Open the vs code file--Preferences--Settings--Search git.path in the input box


Then manually enter your git.exe installation path in the user settings on the right

For example my installation is at:


Then enter the path on the right:

Note here: The slashes in the directory should be changed to " / " in Linux style , instead of " \ " in the Windows directory , otherwise an error will be reported

Change Ctrl+s to save, then restart vs code to solve the problem


another situation

If you return the following abnormal results after git in CMD:


Then it is because of the problem of the null.sys file

Win7 users directly right-click Computer - Manage - View, check Show hidden devices:

Click on the non-plug and play driver on the right side  ---find null--- right click on Null-property-driver-if it has been started, click stop, then click start, select the type to start, and you're done


Unfortunately win10 no longer has this setting

The only way is to copy a null.sys file to replace the null.sys in the C:\Windows\System32\drivers directory, and then restart your computer, and you are done. This is a download address found, and the test is available.

https://pan.baidu.com/s/1JCGfMCmBSN1oCYR2juUHMw

Extraction code: 9f8e

In the same way, the problem of flashback of the Git component in the menu when the win key is clicked is also solved in the same way.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324656014&siteId=291194637
Git