解决Error: [email protected] has been disabled because it is a versioned formula
2023-2-21 23:42:6 Author: www.uedbox.com(查看原文) 阅读量:190 收藏

问题

brew安装php7.4报错

Error: php@7.4 has been disabled because it is a versioned formula!

解决方法

brew install shivammathur/php/php@7.4

更新 PATH in .zshrc:

echo 'export PATH="/opt/homebrew/opt/[email protected]/bin:$PATH"' >> ~/.zshrc

echo 'export PATH="/opt/homebrew/opt/[email protected]/sbin:$PATH"' >> ~/.zshrc

source ~/.zshrc

检查版本

$ php -v

PHP 7.4.33 (cli) (built: Jan 21 2023 06:43:54) ( NTS )

Copyright (c) The PHP Group

Zend Engine v3.4.0, Copyright (c) Zend Technologies

    with Zend OPcache v7.4.33, Copyright (c), by Zend Technologies


文章来源: https://www.uedbox.com/post/68765/
如有侵权请联系:admin#unsafe.sh