Skip to content

Instantly share code, notes, and snippets.

@kamermanpr
Last active November 9, 2023 17:50
Show Gist options
  • Save kamermanpr/23bc20180dc277bc8043558f0c22f8a9 to your computer and use it in GitHub Desktop.
Save kamermanpr/23bc20180dc277bc8043558f0c22f8a9 to your computer and use it in GitHub Desktop.
Install Xcode Command Line Tools, Homebrew, and Git on macOS

Install Xcode command line tools, Homebrew, and Git on macOS

Install the following apps on your mac running macOS:

  1. (standalone) Xcode Command Line Tools
  2. Homebrew
  3. Git

Modified from: https://www.moncefbelyamani.com


Install Xcode Command Line Tools

  • Copy and paste the following text into your terminal (and press "return"):
xcode-select --install
  • Follow the prompts.

Install Homebrew

Homebrew is a package manager for macOS/OSX that allows the easy installation of hundreds of open-source tools.

  • Copy and paste the following text into your terminal (and press "return"):
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
  • Wait for the installation to proceed.

  • To verify the installation, copy and pastethe following text into your terminal (and press "return"):

brew doctor
  • You should see, Your system is ready to brew printed in the terminal.

Install Git

Git is pre-installed on macOS, but this step will update your machine to the latest version of git.

  • Copy and paste the following text into your terminal (and press "return", after each step):
brew install git
  • Wait for the installation to proceed.

  • To verify the installation, copy and pastethe following text into your terminal (and press "return"):

git --version
  • You should see, git version 2.18 or later printed in the terminal.

  • To update Git at a later stage, copy and paste the following text into your terminal (and press "return"):

brew upgrade git
@davidladkins
Copy link

perfect thank you

@AngZiqi
Copy link

AngZiqi commented Jul 19, 2022

perfect thanks a lot

@ayycee25
Copy link

Why is this installation text different from the one on the homebrew website : /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" . What difference does /usr/bin/ruby -e and the exclusion of .sh at the end do for mac?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment