7

Maybe it's awkward, but I can't run .sh file on Windows when working in Git shell. Probably I have to install something, but I thought that Git will support that bash command (I know Windows don't use sh files).

I am doing installation steps from GameClosure and after $ ./install.sh a window with application selection to open sh file appears (like that when you try to open unknown file in Windows, it asks what application to open this you would like to use). I've tried open it with Git shell, but failed... What I have to do to run this file and proceed with installation steps from GameClosure tutorial?**

Here is a screenshot (alert in polish, but I think you all know this message). Screenshot (Polish)

Szorstki
  • 1,324
  • 1
  • 10
  • 16

3 Answers3

6

Try using the git-bash available with msysgit, with the Git Bash.vbs shortcut.

Msysgit is also packaged within GitHub for Windows, even though the shell exposed is a Powershell one based on posh-git. That (powershell) would explain why *.sh scripts cannot run on it.

The OP Szorstki mentions in the comment that there actually is a setting in the GitHub for Windows app, that can set up Git Bash as the default command line tool.

Community
  • 1
  • 1
VonC
  • 1,042,979
  • 435
  • 3,649
  • 4,283
  • Ok, thanks - there is configuration in GitHub windows app, that can set up Git Bash as the default command line tool. – Szorstki May 27 '13 at 11:50
  • 1
    @Szorstki no, as I have linked in the answer: http://stackoverflow.com/questions/11928561/where-is-git-exe-located : msysgit is packaged within GitHub for Windows. You can then launch the Git Bash script which will run a msys Unix-type compatible shell (as explained in the [msysgit FAQ](https://github.com/msysgit/msysgit/wiki/Frequently-Asked-Questions)). – VonC May 27 '13 at 11:51
1

Try installing bash for Windows and running the script ag again after executing bash from cmd.exe.

hd1
  • 30,506
  • 4
  • 69
  • 81
0

Invokes the right shell, no unnecessary windows and invokes a bash script afterwards which will be hold.

  • Create a Shortcut to mintty.exe on your desktop, for example

  • Edit properties of the shortcut and change the target (keep the path):

  • C:\Program Files\Git\usr\bin\mintty.exe" -h always /bin/bash -l -e 'D:\folder\script.sh'

Hannes Schneidermayer
  • 2,860
  • 2
  • 21
  • 23