How To Install Command Line Tools & Homebrew On macOS (Catalina or Older macOS Version)Without Xcode.
This article shows how to install Command Line Tools and brew on macOS with simple steps.
Command Line Tools: Mac users get access to useful tools, utilities and compilers, including make, GCC, clang, perl, svn, git, size, strip, strings, liptool, cpp and many other useful commands that are part of Linux installations.
Homebrew: It’s a free and open-source software package management system that simplifies the installation of software on Apple’s macOS operating system and Linux.
Contents:
1. Installing Command Line Tools
2. Installing Homebrew
3. To Update Homebrew
INSTALLING COMMAND LINE TOOLS
- Launch terminal, go to Applications → Terminal.
- Type the following below command to install command line developer tools package.
xcode-select --install
3. A software update popup window will appear and asks for “xcode-select command requires the command line developer tools. Would you like to install the tools now”, choose Install to confirm the installation, then Agree to the Command Line Tools License Agreement (read the agreement thoroughly).
4. Next, command line developer tools start downloading the software, wait for the command line tools package download to complete, download time based on the internet speed.
INSTALLING HOMEBREW
- Visit Homebrew webpage https://brew.sh/.
- Copy the homebrew installation command, as shown under Install Homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
3. Launch terminal, go to Applications → Terminal and paste the above Homebrew command.
4. After running the homebrew command, if the terminal prompts for sudo xcodebuild -license, run the command shown below, then agree the license agreements.
sudo xcodebuild -license
5. Then now again run the Homebrew command after agreed to the Xcode license,
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
TO UPDATE HOMEBREW
- To update the Homebrew use the command shown below,
brew update