Why is "MINGW64" appearing on my Git bash?

MINGW64 is 'Minimum GNU for Windows 64 bit'. It's the name of a compiler used to build an extra copy of bash that "git for Windows" includes.

"Git for Windows" includes git plus a variety of additional software, which you may already have on your machine. This includes:

  • bash (which already comes with Windows 10 and 11)
  • ssh (which is also now included in Windows 10 and 11)
  • Shell preferences for a PS1 (the prompt, where the pink MINGW64 comes from), a shortcut file, and some other tools.

As PS1 tastes are generally personal you may prefer your existing setup.

If you want git, but don't want all the extra software

  • You can get a minimal build from nuget if you don't have any git apps installed.

  • But if you use a GUI that may also include an embedded git - personally I use the one included with Sourcetree. In my powershell profile:

    Add-PathVariable "${env:UserProfile}\AppData\Local\Atlassian\SourceTree\git_local\bin"

This provides git without any additional changes to your system or extra copies of other software.

(Add-Pathvariable comes from PSCX by the way)


Easiest way to remove 'MINGW64' is to comment two lines in file:

\Git\etc\profile.d\git-prompt.sh
...
# PS1="$PS1"'\[\033[35m\]'       # change to purple
# PS1="$PS1"'$MSYSTEM '          # show MSYSTEM

This is the new icon being used with Git for Windows 2.x. The website needs an update for that I guess but there are not many volunteers typically.

The MINGW64 is the value from the MSYSTEM environment variable. This has been included in the bash prompt by setting PS1 in the /etc/bash.bashrc file. You can either override this in your own $HOME/.profile or edit the distributed one to remove that if you prefer.