Installing Xcode and Homebrew in Macbook M1

Shrayan Bandyopadhyay
2 min readOct 30, 2021

--

This paper consists of commands to install Xcode and Homebrew in Apple Silicone MacBooks

Paste the codes given below into your terminal. I have provided all the relevant codes keeping in mind that you have a brand new MacBook and Xcode, Python 3.8, et cetera are not installed.

Installing Apple Command Line Tools

Run these codes individually.

sudo xcodebuild -licensesudo xcode-select --install

Installing Homebrew on Apple Silicone

/usr/bin/ruby -e "%(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

In case there is any warning such as,

/opt/homebrew/bin is not in your PATH

create .zshrc on home directory (If it was not created yet). Just run the command below on a zsh terminal:

touch .zshrc

Then open it to edit with TextEdit (Is a hidden file. You can show hidden files with “shift” + “command” + “.” ) or type,

nano ~/.zshrc

and add the line below at the end of .zshrc.

export PATH=/opt/homebrew/bin:$PATH

Next open your terminal again and run:

source ~/.zshrc

Now just run this command to be sure that everything is working:

brew help

Want to know how to install tensorflow on Apple MacBook M1. Here’s an article for you!

Sign up to discover human stories that deepen your understanding of the world.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

Shrayan Bandyopadhyay
Shrayan Bandyopadhyay

Written by Shrayan Bandyopadhyay

Create a tidal wave and not a ripple.

No responses yet

Write a response