Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Git-Bash Command Prompt won't open up after upgrading to Windows 10

I just upgraded my OS to Windows 10 and Git Bash won't even open up anymore. I might need to uninstall and re-install it again but I was just wondering if anyone else ran into this problem after upgrading to Windows 10 and what their fix was other than un-installing and re-installing ?

like image 799
pelican Avatar asked Aug 07 '15 22:08

pelican


2 Answers

I have to face the same problem when upgraded my windows from 7 to 10. I tried by reinstalling the git bash but re installation not works for me.it is due to the permission issue with the shell script parser sh.exe file. all you need to do is use bash as your shell script parser instead of sh.

you can do that as below.

Step 1:

Resolve the issue with the shortcut

  • right click and open properties dialog of the Git Bash short cut located in your desktop or in your start menu (C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Git\Git Bash.lnk in my PC), you will see the below Target in the "Short cut" tab.

    "C:\Program Files\Git\bin\sh.exe" --login -i"

    just replace sh.exe to bash.exe as below

    "C:\Program Files\Git\bin\bash.exe" --login -i"

Step 2 :

  • Resolve the problems with the sh commands.

    Go to the Git Bash bin folder (C:\Program Files\Git\bin in my PC)

    Take a backup : copy the sh.exe file into old-sh.exe and delete the sh.exe file

    open the git bash and execute below commands.

    • cd /bin
    • ln /bin/bash.exe sh

it worked for me. don't know the same will workout for you.

like image 196
Dhayal Avatar answered Oct 09 '22 20:10

Dhayal


There have been few instances where other users who have upgraded to windows 10 are facing similar issues with respect to Git Bash and git in general. An issue has been opened with msysgit on GitHub. Official clarification will be posted on that page very soon.

A similar issue but not related to Git Bash particularly on Windows 10 platform is being resolved here.

If your issue is not very serious, it is advisable to uninstall and install an appropriate version of Git Bash for Windows 10.

like image 20
Anantha Raju C Avatar answered Oct 09 '22 18:10

Anantha Raju C