7
10

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

M1 Macで Homebrewインストールした時のメモ

Posted at

MacOS ARMでは /opt/homebrew にインストールしてくださいとの記述がある。

Installation — Homebrew Documentation
image.png

# /opt/homebrewのディレクトリ作成
sudo mkdir /opt/homebrew
chown ${自分自身USER名} /opt/homebrew

# HomebrewのGitからcloneする。
sudo curl -L https://github.com/Homebrew/brew/tarball/master | tar xz --strip 1 -C homebrew

# brewコマンドのPATHを通す
sudo vi /etc/paths
## 下記内容を/etc/paths/に追加
/opt/homebrew/bin

# brewのキャッシュパス設定
sudo vi ~/.zshrc
## 下記を ~/.zshrc に追加。
export HOMEBREW_CACHE=/opt/homebrew/cache

# brewコマンドの確認 --prefixはbrewのインストール先を返す。
brew --prefix

参考にしたサイト

Installation — Homebrew Documentation
Homebrew のインストール先を変更する - Qiita
PATHを通すとは? (Mac OS X) - Qiita
macos - OSX: Cannot unlock etc/paths file - Super User

7
10
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
7
10

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?