Pre-Step:
Git For Windows should be installed on your machine, and make sure you have information about installation path of Git. By default selected paths are (C:\Program Files\Git or C:\Program Files (x86)\Git)
Now you need to register Git in the windows environment variable ecosystem.
Step 1:
Using My Computer or Windows Explorer(explorer.exe), right click on My Computer and select Properties.
Step 2:
From the left pane, select Advanced System Settings option.
Step 3:
In Advanced Tab, Select Environment Variables button from the bottom of the window.
Step 4:
From System Variables, try to find Path variable and then click on edit to add Git to it.
Step 5:
For Windows 10:
Add reference of Git CMD and Binary to Path Variable as two separate values
%PROGRAMFILES(x86)%\Git\bin
%PROGRAMFILES(x86)%\Git\cmd
For Win 7/8:
Add reference of Git CMD and Binary to Path Variable at the end of the string like this:
;%PROGRAMFILES(x86)%\Git\bin;%PROGRAMFILES(x86)%\Git\cmd
Step 6:
Now Restart CMD/PowerShell after Path variable update
Voila, type git
in CMD/Powershell and now make sure that it recognize the command.
Nice work. Tank u very much.
LikeLike