Step-by-Step Guide: How to Install Git on Mac

ยท

1 min read

Using Homebrew is a popular package manager for macOS, which simplifies the installation process.

  1. Open the "Terminal" application. You can find it in the "Utilities" folder within the "Applications" folder, or you can use Spotlight search (Cmd + Space) and type "Terminal".

  2. Install Homebrew (if you haven't already) by pasting the following command into the Terminal and pressing Enter:

     /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
    
  3. Once Homebrew is installed, use the following command to install Git:

brew install git

Homebrew will handle the installation and dependencies automatically. After the process is complete, Git will be installed on your Mac.

To verify that Git is installed and check its version, run the following command in the Terminal:

git --version

That's it! We have installed Git on Mac, and it can be used for version control and collaborating on projects.

ย