Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Differences between Git-scm, msysGit & Git for Windows

What is the difference between git-scm (downloaded from git-scm.com) and msysGit (hosted on Google Code, Github, and probably others)? They both seem pretty similar, and even though I have git-scm, I have applied fixes specified for msysGit and they seem to work fine.

Also, which one, if either, is Git for Windows, and are both called Git Bash, or do both have the Git Bash shell, or only one of the two?

like image 717
trysis Avatar asked Mar 10 '14 19:03

trysis


People also ask

Is Git SCM same as Git?

There is no “Git-SCM”, that's just the URL of the source control management (SCM) software—the name is just Git.

What is msysGit?

msysGit is the development environment to compile Git for Windows. It is complete, in the sense that you just need to install msysGit, and then you can build Git. Without installing any 3rd-party software. msysGit is not Git for Windows; that is an installer which installs Git -- and only Git.

What is Git SCM and GitHub?

GitHub- As mentioned earlier, Git is a version control system that tracks code changes, while GitHub is a web-based Git version control repository hosting service. It provides all of the distributed version control and source code management (SCM) functionalities of Git while topping it with a few of its own features.

What is the difference between standalone and portable Git?

Portable Git is a completely standalone version of the Git distributed version control system. All you need do to get going is to download a file and unzip it into a folder.


1 Answers

The website git-scm.com is the official website for Git, the version control software. There is no “Git-SCM”, that’s just the URL of the source control management (SCM) software—the name is just Git. Originally written for Linux, the original Git software is only available as a source that doesn’t compile easily on Windows.

If you are just interested in installing Git on Windows, then you can stop reading here and just download a Windows build from the official website.

Git for Windows

Git for Windows is the project dedicated to building native builds of Git for Windows. The Windows releases are available for download on the official Git website, they come as 32-bit and 64-bit builds.

Git for Windows is built on top of MSYS2 (a part of MinGW) which provides a minimal unix-like shell environment which is used to run all the components of Git which are not written in native code (a lot of Git is written as shell scripts). In order to build Git with MSYS2, the project group has a special “Git for Windows SDK” which is basically the whole build environment needed to build Git on Windows, and comes with everything you need to start working on Git itself.

The project maintains its own fork of Git which is kept up to date with the original Git project but contains a set of patches necessary to build it on Windows. Git for Windows releases are usually released with a short delay after the official version is released (although versions are sometimes skipped).

msysGit

Prior to Git version 2, the Git for Windows binaries were released by the project called msysGit, which is the predecessor of the Git for Windows project. The project was retired on August 18, 2015 in favor to launch the Git for Windows project with the rebuilt Git for Windows SDK development environment. The new project was mostly started with the same team.

While many people thought of msysGit as the name of the Git binaries, that was actually the name of the development environment they created. It was based on MSYS, the older and kind-of outdated version before MSYS2 was started fresh. The bad state of MSYS was one of the reasons why the Git for Windows project was started with a completely revamped build environment.

The project essentially released three things: msysGit, Git for Windows, and a portable Git for Windows. The msysGit installer would install and set up the development environment required to build Git on Windows, just like the Git for Windows SDK does now. Git for Windows was an installer that would install Git on a Windows machine, and the portable Git for Windows were just the binaries you wouldn’t have to install. Note that all their releases were released as “preview” builds, meaning that they would not be fully supported releases. Despite that, the project was very mature and the releases were very stable and the de-facto best way to set up Git on Windows.

Git Bash

As mentioned above, a lot of Git is written as shell scripts. In order to execute those scripts, Git for Windows uses Bash that comes bundled with MSYS2 (so Bash works as an interpreter for it).

Git Bash commonly refers to the shortcut the Git for Windows installer creates. It launches a full featured console window running Bash, so you can use Git as well as a set of common command line tools or Unix programs (like less, awk, grep, or even the text editor vim). Especially for less experienced users, Git Bash is the common way to interact with Git, although you could easily use it from more Windows-centric environments like PowerShell.

Starting with Git version 2, Git Bash will by default launch in MinTTY, a terminal emulator which comes with MSYS2, making it easily usable even for users not accustomed to a console experience.

It’s also useful to know that Git Bash will always work even if you decided not to add any Git executables to your PATH during the setup of Git for Windows. However, my personal recommendation is to add the Git executable (just the Git executable, choosing the option “Use Git from the Windows Command Prompt” during setup) to the PATH. That way, you can work with Git from other shells (cmd.exe or PowerShell), and other programs can access it too (e.g. many libraries or even IDE integrations expect a Git executable in the PATH to interact with Git repositories).

like image 62
poke Avatar answered Oct 12 '22 16:10

poke