Skip to content

Installing git on Macs

David Ryder edited this page May 13, 2025 · 3 revisions

OS X Installation using mambaforge

This should work on any Mac running OS 10.9 or later, with an intel or silicon processor.

  1. Open 'Terminal' (which is an app included with every copy of OS X).

  2. Download mambaforge:

curl -L -O https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-MacOSX-x86_64.sh

  1. Install mambaforge:

sh Miniforge3-MacOSX-x86_64.sh

  1. Agree to continue with the installation, if you are warned about the computer not being 64-bit, agree to the license, and when the installer offers to intialize Mambaforge type 'yes'.

  2. Close the terminal and then open it again (using the menu or '⌘' + 'N' shortcut).

  3. Create an environment with the latest version of git and gh installed:

mamba create --name=git git gh

  1. Activate the environment.

mamba activate git

  1. Authenticate git using your GitHub credentials:

gh auth login

  1. Keep pressing the return key.

  2. Eventually a tab on your internet browser should open a page from GitHub's website.

  3. Login, enter the one-time code output by gh, and then click the 'Authorize github' button to grant git access to your GitHub credentials.

Clone this wiki locally