首页 > 代码库 > Mac安装composer爬过的坑
Mac安装composer爬过的坑
1.首先安装brew
/usr/bin/ruby -e "$(curl -fsSLhttps://raw.githubusercontent.com/Homebrew/install/master/install)"
2.安装composer
brew install composer
安装的composer可能还不是最新版本的,可以升级一下
composer self-update
可能会报错。代码为:
Error: No available formula with the name "php56-redis" ==> Searching for a previously deleted formula... Error: No previously deleted formula found. ==> Searching for similarly named formulae... Error: No similarly named formulae found. ==> Searching taps... Error: No formulae found in taps.
3.在brew中添加tap
brew tap homebrew/homebrew-php
4.php56-redis 扩展
brew install php56-redis
就能安装成功了,此过程需要一些时间,大概十分钟左右
5.不要忘了重启apache
sudo apachectl restart
6.安装composer
brew install composer
截图:
7.验证composer
Mac安装composer爬过的坑
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。