0

Hi i am willing to use Git Bash for app dev, however whenever i start it, it gives me couple of 'bash :export:' lines and not even the clear/clrscr commands work. I am using a Windows 8.1 machine (6.00 gb ram, 1 TB - just so you know). I have tried the following:

  • uninstalling-reinstalling git
  • Using Git as CMD prompt

Below is the screenshot of the Terminal window:

enter image description here

Output of echo $PATH

enter image description here

This is my current PATH env variable:

C:\Users\Madhukar Jain.npm-global\node_modules\express;C:\Users\Madhukar Jain\AppData\Roaming\npm;%APPDATA%\Roaming\npm\node_modules.bin\;C:\Program Files\MongoDB\Server\3.2\bin;C:\Program Files (x86)\Microsoft VS Code\bin;C:\Program Files\Git\bin;C:\Program Files\Git\cmd;

Arjun Jain
  • 49
  • 1
  • 2
  • 14

2 Answers2

0

Looks like the PATH is completely messed up. Are you using custom profile/rc file such as ~/.bashrc , ~/.bash_profile , ~/.bash_login or ~/.profile ? If yes you need to check whether the contents are syntactically correct. From the errors I feel that there are few issues with special characters such as spaces. You may have to use double quotes properly to clearly differentiate the directories in the PATH.

asatsi
  • 452
  • 2
  • 5
  • This is my PATH variable: C:\Users\Madhukar Jain\.npm-global\node_modules\express;C:\Users\Madhukar Jain\AppData\Roaming\npm;%APPDATA%\Roaming\npm\node_modules\.bin\;C:\Program Files\MongoDB\Server\3.2\bin;C:\Program Files (x86)\Microsoft VS Code\bin;C:\Program Files\Git\bin;C:\Program Files\Git\cmd; – Arjun Jain Jun 12 '17 at 10:53
  • also since i have just reinstalled Git bash, i did not touch any of those mentioned files. – Arjun Jain Jun 12 '17 at 10:58
  • Turns out there was an 'export PATH' statement in my .bash_profile file. Apparently that remains untouched even after you reinstall git. Erasing its contents helped. – Arjun Jain Jun 13 '17 at 07:08
0

Try this and check

export PATH=$PATH:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin  
skr
  • 2,146
  • 19
  • 22