mac homebrew 安装

Homebrew has enabled anonymous aggregate formulae and cask analytics.

Read the analytics documentation (and how to opt-out) here:

No analytics data has been sent yet.

Homebrew is run entirely by unpaid volunteers. Please consider donating:

Next steps:

  • To add Homebrew to your PATH, add to your shell profile (e.g. ~/.bash_profile or ~/.zprofile):
    • eval "$(/opt/homebrew/bin/brew shellenv)" on Apple Silicon
    • eval "$(/usr/local/bin/brew shellenv)" on Intel
  • Run brew help to get started
  • Further documentation:

Rm -rf ~/.zsh.... // 删除历史记录

Echo $SHELL // 查看用的是哪个终端

cat /etc/shells // 查看所有的终端

Chsh -s /bin/zsh // 切换成 zsh 终端

  • 打开"终端"。
  • 输入命令 chsh -s /bin/bash 来切换到 bash。
  • 输入命令 chsh -s /bin/zsh 来切换回 zsh。

打开 moren 的终端: open ~/.zshrc ,没有的情况就自动创建一个:touch ~/.zhsrc

查找安装目录:which brew

larave@laraveldeMacBook-Pro ~ % which brew

/opt/homebrew/bin/brew

配制环境变量:export PATH=${PATH}:/usr/local/xxx(你的地址)

export PATH="/usr/local/Homebrew/bin:$PATH"

以下两个链接:安装brew

重要的源文件链接: 清华源:

https://mirrors.tuna.tsinghua.edu.cn/help/homebrew/

https://www.bilibili.com/video/BV1TJ4m157Sm/?spm_id_from=333.337.search-card.all.click\&vd_source=3fa570246e6039c5aaa3b3950fd03f45

Mac安装Homebrew实操_哔哩哔哩_bilibili

以下是一键执行操作:

https://zhuanlan.zhihu.com/p/111014448

这个链接可以看看:

【Mac】6: 苹果电脑必装大神器 Homebrew !没有装它,你的苹果电脑就不能发挥最大作用_哔哩哔哩_bilibili

Xcode 安装 :

Command Line Tools

xcode-select 是 macOS 上的一个命令行工具,可以帮助你在终端中管理当前使用的 Xcode 版本

如果已经安装过Xcode Command Line Tools,那么需要把之前安装的删除,再安装:

rm -rf /Library/Developer/CommandLineTools

xcode-select --install

确认Xcode Command Line Tools正确安装在:/Library/Developer/CommandLineTools

xcode-select -p

确认安装版本

xcode-select --version

相关推荐
普通网友3 小时前
苹果笔记本(Mac)连接手机完全指南
macos·智能手机
Aftery的博客5 小时前
Xcode运行报错:SDK does not contain ‘libarclite‘ at the path
macos·cocoa·xcode
楚轩努力变强12 小时前
iOS 自动化环境配置指南 (Appium + WebDriverAgent)
javascript·学习·macos·ios·appium·自动化
猫头虎1 天前
如何解决 OpenClaw “Pairing required” 报错:两种官方解决方案详解
网络·windows·网络协议·macos·智能路由器·pip·scipy
皮卡车厘子2 天前
Mac 挂载目录
macos
良逍Ai出海2 天前
在 Windows & macOS 上安装 Claude Code,并使用第三方 Key 的完整教程
windows·macos
热爱生活的五柒2 天前
linux/mac/wsl如何使用claude code,并配置免费的硅基流动API?(官方的需要付费订阅)
linux·运维·macos
胖胖大王叫我来巡山3 天前
mac本地安装DataEase桌面版
macos
奋斗者1号3 天前
OpenClaw 部署方式对比:云端、WSL、Mac 本机、Ubuntu 虚拟机(2026年2月最新主流实践)
linux·ubuntu·macos
玉梅小洋3 天前
Android SDK 安装指南(MacOS 和 Windows)
android·windows·macos·sdk