Note that this site is in currently in version 1.0.0-alpha.   Some functionality may be limited.

How to install Git (and Git Bash) for macos

Git is a version control software used to manage and track changes made to files and project folders over time. We will be installing it on our local machine and live on the hard drive on your laptop. Note that Git is a separate software than GitHub. Alternatively, GitHub is a web-based software that lives on the Internet. You can create an account at github.com. These instructions are for Git, not GitHub.

For the Digital Humanities Research Institute, we use Git because it is an open-source tool that was built to support individual version control needs as well as collaborations across time and space. In our curriculum, it is one of the foundational tools we teach because through understanding how Git works, we learn a lot more about how computers and different softwares work.

Step 1: Type the following command into the terminal

Using the terminal, we will use a set of specific phrases - or commands - that tell the computer what we want it to do. First, we want to tell the computer to install the Command Line Tool Package. This give Mac users many commonly used tools, utilities, and compilers, including make, GCC, clang, perl, svn, size, strip, strings, libtool, cpp, what—and Git. Install this package by typing the following command into your terminal and clicking enter.

$ xcode-select --install

Image shows terminal, a black box in which you can enter text to interact with your computer. Look for your username and the dollar sign at the top. Image shows terminal with the above command typed in.

Step 2: Test the Install

Now, let’s make sure Git has been installed successfully.

  • Type the following command into the terminal:
$ git

The terminal should print something like (note that this is truncated):

usage: git [--version] [--help] [-C <path>] [-c name=value]
           [--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]
           [-p | --paginate | --no-pager] [--no-replace-objects] [--bare]
           [--git-dir=<path>] [--work-tree=<path>] [--namespace=<name>]
           <command> [<args>]

shows terminal on mac osx