Mac 升级之brew 伤

来源:互联网 发布:金星秀网络更新时间 编辑:程序博客网 时间:2024/04/29 16:26

事初: 在 Mac 环境下, 给 phpstorm 配置 xdebug
方法: brew install homebrew/php/php70-xdebug [快捷方式,不要问我为什么]
结果:
1. git 版本
2. Git must be installed and in your PATH! [最重要提示]
其他介个结果找记不清了不重要,后面解释!

what ? 之前安装mysql,安装redis 都没有提!

着急忙活一通乱搜,升级 brew、卸载git、 xdebug 编译安装(中间又出错了),然后想了想静静!

补充:xdebug 编译安装错误:
autom4te: need GNU m4 1.4 or later: /usr/bin/m4 (又是一通乱搜)

最终解决方案:

原因:11月底刚刚升级了 macOS 【坑、坑、坑...】用mac 刚一年看考地址:https://enginx.net/2016/08/18/%E6%9B%B4%E6%96%B0macos-sierra%E5%90%8Ebrew%E5%87%BA%E7%8E%B0%E9%94%99%E8%AF%AF%E7%9A%84%E4%BF%AE%E5%A4%8D%E6%96%B9%E6%B3%95.html【强烈放到收藏夹】在搜索引擎中看到,就是没有点进取.. 快速浏览之后,发现了 'xcode-select --install', 没有多想,在命令行立刻执行, 等了会,重新brew update 在执行 brew install homebrew/php/php70-xdebug 一切OK

总结:
1.尽可能别升级
2.不折腾永远不知道怎么解决问题,例如:解决问题方式对不对,需要不要改进?
3.得补英文
4.认真看抛出的错误

在参考 6 文章时,提示’xcode-select –install’ 但是不知道啥用,就没理他,害我花了1个小时搜索其他内容

其他参考:

1.brew doctor Warning: How to add git to PATH? 一样的问题但是给出的答案都不行https://stackoverflow.com/questions/36237537/brew-doctor-warning-how-to-add-git-to-path?answertab=active#tab-top2.https://segmentfault.com/q/10100000072510763.http://blog.csdn.net/gaohanyu111/article/details/785223884.https://www.v2ex.com/t/148303 5.http://blog.csdn.net/aimimi2015/article/details/730608916.http://blog.csdn.net/sinat_35200773/article/details/52304442 (git在mac环境下升级的方法)
原创粉丝点击