Mac本地安装PHP@7.4版本 - 2024

为什么要安装v7.4版本的php?

业务的需求,需要使用php@7.4版本;

Mac本地默认是php@8,且brew install php@7.4,提示,具体看下如下图:

Warning: shivammathur/php/php@7.4 has been deprecated because it is a versioned formula!

如何安装在Mac上安装php@7.4版本?

在网上找到一个大家都提到的一个GItHub项目:https://github.com/shivammathur/homebrew-php/

支持全部的PHP版本:

安装教程如下:

For example, to install PHP 7.4:

bash 复制代码
brew install shivammathur/php/php@7.4

After installing you have to link it:

bash 复制代码
brew link --overwrite --force shivammathur/php/php@7.4

Restart the terminal and test your PHP version:

bash 复制代码
php -v
相关推荐
没有梦想的咸鱼185-1037-166323 分钟前
基于R语言机器学习方法在生态经济学领域中的实践技术应用
开发语言·机器学习·数据分析·r语言
向上的车轮1 小时前
基于go语言的云原生TodoList Demo 项目,验证云原生核心特性
开发语言·云原生·golang
The Chosen One9851 小时前
C++ : AVL树-详解
开发语言·c++
PH_modest1 小时前
【Qt跬步积累】—— 初识Qt
开发语言·qt
怀旧,1 小时前
【C++】18. 红⿊树实现
开发语言·c++
xiaopengbc2 小时前
在 Python 中实现观察者模式的具体步骤是什么?
开发语言·python·观察者模式
Python大数据分析@2 小时前
python用selenium怎么规避检测?
开发语言·python·selenium·网络爬虫
ThreeAu.2 小时前
Miniconda3搭建Selenium的python虚拟环境全攻略
开发语言·python·selenium·minicoda·python环境配置
zhangfeng11332 小时前
R 语法高亮为什么没有,是需要安装专用的编辑软件,R语言自带的R-gui 功能还是比较简单
开发语言·r语言