4

I have a simple question. What is Git Shell? IS it the same as Windows Power Shell?

Because when I run Git Shell on my Windows 7 machine the Windows Power Shell is opened.

Thanks for clarification.

11

When you install GitHub for Windows, you can assign the shell dynamically:

Go to Tools, then options...

Select your preferred shell

Which type is picked by default is decided during setup.

  • Btw. has PowerShell more benefits than using just Git Bash? I am new in this area, so thanks for any advice. – Derfder Nov 22 '12 at 11:45
  • @Derfder: If you like to use PowerShell cmdlets, use the PowerShell. If you're more familiar with bash, use the Git Bash. In regards to git itself, I never noticed a difference. – Der Hochstapler Nov 22 '12 at 11:48
  • So, what do you use personally on a daily basis, if I may ask? – Derfder Nov 22 '12 at 12:08
  • @Derfder: I use the PowerShell host. I like bash better in general, but working with bash on Windows just feels weird to me. – Der Hochstapler Nov 22 '12 at 12:30
3

If you're using msysgit then the git shell is actually a msys shell that utilizes MinGW and provides a bash shell implementation for windows.

Because msys leverages MinGW it also provides reimplementation of some of the standard GNU programs written for windows that are useful when operating git.

  • I have an icon on my desktop called "Git Shell" (that comes with Git for windwos installer) . And when I double click it Windows Power Shell starts. Why? – Derfder Nov 22 '12 at 11:00
  • There's a number of possible reasons, maybe the shortcut is broken or sh.exe is aliased to Windows PowerShell. Either way Git Shell is a separate entity to PowerShell – Jake Woods Nov 22 '12 at 11:03
  • Where is sh.exe located, so I can start it? – Derfder Nov 22 '12 at 11:05
  • Typically the areas where you command line programs come from (like sh.exe) can be found in the PATH variable. If you do echo %PATH% in a regular shell that will show you all the possible folders it could be in. – Jake Woods Nov 22 '12 at 11:27
  • 1
    In bash it would be $PATH – Jake Woods Jan 2 '13 at 3:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.