==> Checking for `sudo` access (which may request your password)... Password: ==> This script will install: /usr/local/bin/brew /usr/local/share/doc/homebrew /usr/local/share/man/man1/brew.1 /usr/local/share/zsh/site-functions/_brew /usr/local/etc/bash_completion.d/brew /usr/local/Homebrew ==> The following new directories will be created: /usr/local/Cellar /usr/local/Caskroom ==> HOMEBREW_BREW_GIT_REMOTE is set to a non-default URL: https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/brew.git will be used as the Homebrew/brew Git remote. ==> HOMEBREW_CORE_GIT_REMOTE is set to a non-default URL: https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git will be used as the Homebrew/homebrew-core Git remote.
成功了,哈哈。 远程脚本检测到本地设置了环境变量,直接启用了清华的软件源。
然后安装PHP
1 2 3 4 5 6 7 8
brew install php@7.4 HOMEBREW_BREW_GIT_REMOTE set: using https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/brew.git for Homebrew/brew Git remote. HOMEBREW_CORE_GIT_REMOTE set: using https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git for Homebrew/core Git remote. Running `brew update --preinstall`... Warning: php@7.4 has been deprecated because it is a versioned formula! ==> Downloading https://mirrors.tuna.tsinghua.edu.cn/homebrew-bottles/apr-1.7.0_2.monterey.bottle.tar.gz ######################################################################## 100.0% ..................