报错

“-bash: brew: command not found”

执行下面命令,安装HomeBrew

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

此时报错:

Error: Failure while executing: git clone https://github.com/Homebrew/homebrew-core /usr/local/Library/Taps/homebrew/homebrew-core --config core.autocrlf=false --depth=1 -q
Error: Failure while executing: /usr/local/bin/brew tap homebrew/core -q

依次执行下面两行命令即可成功解决

1、sudo chown -R apple:staff *

2、brew doctor

命令执行完之后HomeBrew也就安装好了

好了,小伙伴们,可以开始你们的操作啦

brew install xxx           安装xxx

brew uninstall xxx       卸载xxx

brew update  xxx         更新xxx

brew doctor                 修复brew

mac--“-bash: brew: command not found”,怎么解决?的更多相关文章

  1. 【转】mac终端安装node时候,显示“-bash: brew: command not found”,怎么解决?

    原文网址:https://segmentfault.com/q/1010000004221389/a-1020000004221408 mac终端安装node时候,显示“-bash: brew: co ...

  2. 解决mac安装homebrew后报错-bash: brew: command not found

    解决mac安装homebrew后报错-bash: brew: command not found     参照官网上很简单的一句安装命令, /usr/bin/ruby -e "$(curl ...

  3. 提示-bash: telnet: command not found的解决方法

    Linux centos 运行telnet命令,出现下面的错误提示: [root@localhost ~]# telnet 127.0.0.1 9501 -bash: telnet: command ...

  4. Centos出现-bash: unzip: command not found的解决办法

    利用unzip命令解压缩的时候,出现-bash:  unzip: command not found的错误. unzip——命令没有找到,其原因肯定是没有安装unzip. 利用一句命令就可以解决了.  ...

  5. 【ERROR】bash: vim: command not found的解决办法

    今天在学习鸟哥的菜的时候,发现自己linux不可以启用vim命令,错误为:bash: vim: command not found. 机器环境:VMWare8+RED HAT Enterprise5 ...

  6. mac -bash: ll: command not found

    在linux系统下我们经常使用ll.la命令.但在mac系统时缺没有. 提示:-bash: ll: command not found. 这是因为ll.la不是真的命令,而是一些常用命令和参数搭配的别 ...

  7. Centos提示-bash: make: command not found的解决办法

    一般出现这个-bash: make: command not found提示,是因为安装系统的时候使用的是最小化mini安装,系统没有安装make.vim等常用命令,直接yum安装下即可: yum - ...

  8. -bash: zip: command not found提示解决办法

    -bash: zip: command not found是因为liunx服务器上没有安装zip命令,需要安装一下即可linux安装zip命令:apt-get install zip 或yum ins ...

  9. Linux环境下mysql报错:bash: mysql: command not found 的解决方法

    # mysql -u root-bash: mysql: command not found 原因:这是由于系统默认会查找/usr/bin下的命令. 如果这个命令不在这个目录下,当然会找不到命令. 我 ...

  10. Mac系统下安装Homebrew后无法使用brew命令,-bash: brew: command not found

    使用如下命令: sudo vim .bash_profile 然后输入以下代码: export PATH=/usr/local/bin:$PATH 再使用以下命令使配置生效: source .bash ...

随机推荐

  1. 【iOS】Swipe与Pan区别分析

    By definition, a swipe gesture is necessarily also a pan gesture -- both involve translational movem ...

  2. Kingfisher

    Kingfisher ima1.kf.setImage(with: url) 为了兼容macOS, IOS 通过协议定义了kf,实际上就是本身 KingfisherOptionsInfo 可以配置一些 ...

  3. Oracle dataguard切换实施步骤

    主备库的切换主要在两种情况下切换,Switchover和Failover,这两种切换都需要手工执行完成,不建议自动执行.主库端 192.168.411.20备库端 192.168.411.221 一是 ...

  4. Sass、LESS 和 Stylus各有千秋

    废话不多说直接上连接  为您详细比较三个 CSS 预处理器(框架):Sass.LESS 和 Stylus  

  5. JavaScript 7 获取可视窗口、网页元素、获取节点方式

    获取可视窗口对象 chrom *document.body firefox *document.documentElement 获取滚动条偏移量 ele.scrollTop ele.scrollLef ...

  6. 【学习笔记】C/C++

    1. C语言中的 scanf() 函数 该函数包含在头文件 <stdio.h> 或者 <cstdio> (在C++中使用时) 函数的返回值指的是 所输入的数据与格式字符串匹配的 ...

  7. Mysql的旧版本下载地址

    直接进入:http://downloads.mysql.com/archives/community/

  8. 易优CMS:arclist 文档列表

    arclist 文档列表(配合arcpagelist标签可实现ajax瀑布流分页)  [基础用法] 名称:arclist 功能:获取系统主从表模型(如:文章.软件.图集.产品等)的一列文档,也称自由列 ...

  9. 关于如何将sublime配置C++环境的总结

    首先我得说,嗯,为了这个玩意为翻烂了99%的百度能搜到的文章.研究了关于Win7 32位,64位,Win10版本的配置,Win10的已经写好了一篇文章,可是Win7党(我是都用的,在家用Win10,学 ...

  10. Linux系统目录结构知识

    1.Linux目录结构: 逻辑上所有的目录只有一个顶点 /(根),所有目录的起点.根下面是一个类似倒挂的树的层次结构. 目录的结构和分区设备是没有关系的,也就是不同的目录可以跨越不同的磁盘设备或分区. ...