This repository has been archived by the owner. It is now read-only.
Browse files

Installer: Use sh.exe directly in Git Bash icon if possible (fixes #71).

To avoid side-effects on other cmd.exe windows, point the Git Bash icon
directly to sh.exe on Windows Vista and newer. On 64-bit Windows XP,
launching through 32-bit cmd.exe is required to get sh.exe to launch as
a 32-bit process, but on Windows Vista and newer, this workaround is no
longer required (see commit b6ea386). On
Windows 8, if a start menu link points to cmd.exe but uses a different
icon, that icon is also used by some other cmd.exe windows, even if the
link has command line parameters. On Windows 7, the side-effect is
different; if the Git Bash link uses cmd.exe, Windows groups Git Bash
together with other cmd.exe windows. By avoiding launching through
cmd.exe when it is not necessary, we avoid affecting the icon used by
other cmd.exe windows.

Signed-off-by: David Matson <>
  • Loading branch information...
pointoforder committed Nov 23, 2012
1 parent 31dd6ff commit d5f2b0e00eea7c96788d974f696b6d3bfe9efbd3
Showing with 2 additions and 1 deletion.
  1. +2 −1 share/WinGit/install.iss
@@ -83,7 +83,8 @@ Source: ReleaseNotes.rtf; DestDir: {app}; Flags: isreadme replacesameversion; Af
Name: {group}\Git GUI; Filename: {app}\bin\wish.exe; Parameters: """{app}\libexec\git-core\git-gui"""; WorkingDir: %HOMEDRIVE%%HOMEPATH%; IconFilename: {app}\etc\git.ico
-Name: {group}\Git Bash; Filename: {syswow64}\cmd.exe; Parameters: "/c """"{app}\bin\sh.exe"" --login -i"""; WorkingDir: %HOMEDRIVE%%HOMEPATH%; IconFilename: {app}\etc\git.ico
+Name: {group}\Git Bash; Filename: {syswow64}\cmd.exe; Parameters: "/c """"{app}\bin\sh.exe"" --login -i"""; WorkingDir: %HOMEDRIVE%%HOMEPATH%; IconFilename: {app}\etc\git.ico; OnlyBelowVersion: 6.0
+Name: {group}\Git Bash; Filename: {app}\bin\sh.exe; Parameters: "--login -i"; WorkingDir: %HOMEDRIVE%%HOMEPATH%; IconFilename: {app}\etc\git.ico; MinVersion: 6.0

0 comments on commit d5f2b0e

Please sign in to comment.