M2 macでhomebrewをインストール

2 min 331 views
muraoka

muraoka

pixiv、nanaでプロダクトマネージャーを経験。
現在はマーケティングやwebサービス開発のコンサルティングを行っています。

FOLLOW

M2macbookairでhomebrewをインストールしたのですが、他のmacと少し違ったのでまとめました。

インストール

https://brew.sh/

まずは今まで通り、homebrewをインストールする。

  • ターミナルを開く
  • 一番上の階層に
  • 上記ページのコマンドを叩く

これで下記ででます

Warning: /opt/homebrew/bin is not in your PATH.
  Instructions on how to configure your shell for Homebrew
  can be found in the 'Next steps' section below.
==> Installation successful!

==> Homebrew has enabled anonymous aggregate formulae and cask analytics.
Read the analytics documentation (and how to opt-out) here:
  https://docs.brew.sh/Analytics
No analytics data has been sent yet (nor will any be during this install run).

==> Homebrew is run entirely by unpaid volunteers. Please consider donating:
  https://github.com/Homebrew/brew#donations

==> Next steps:
- Run these three commands in your terminal to add Homebrew to your PATH:
    echo '# Set PATH, MANPATH, etc., for Homebrew.' >> /Users/ユーザー名/.zprofile
    echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> /Users/muraokayouhei/.zprofile
    eval "$(/opt/homebrew/bin/brew shellenv)"
- Run brew help to get started
- Further documentation:
    https://docs.brew.sh

上記でInstallation successful!と出ればinstallは成功

pathを通す

次からがM2macの違うところで、インストールだけではなく、pathを通す必要があります。next stepに書かれているコマンドを叩く必要があるのですが、M2だと3つでています。(M1だと2つ

いろいろ調べましたが下記二つだけでもpathが通りました

echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> /Users/muraokayouhei/.zprofile
    eval "$(/opt/homebrew/bin/brew shellenv)"
muraoka

muraoka

pixiv、nanaでプロダクトマネージャーを経験。
現在はマーケティングやwebサービス開発のコンサルティングを行っています。

FOLLOW

カテゴリー:
関連記事