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

如果安装成功的话,还出现这个问题说明可能是没有配置相关环境变量,那么如何配呢?

我们可以在/usr/local/bin目录下找找是否已经安装了相应命令

ok,我们可以看到brew命令是有的,那么我们只需要把这个命令的路径配置到系统环境变量即可。

sudo vim /etc/profile

文件底部加入

PATH=".;$PATH:/usr/local/bin"

PATH路径是通过“:"进行分割的,在后面添加/usr/local/bin,然后重新打开命令行,就可以使用brew命令。

-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. Mac系统下安装Homebrew后无法使用brew命令,-bash: brew: command not found

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

  4. mac--“-bash: brew: command not found”,怎么解决?

    报错 “-bash: brew: command not found” 执行下面命令,安装HomeBrew ruby -e "$(curl -fsSL https://raw.githubu ...

  5. scp报错 -bash: scp: command not found

    环境:RHEL6.5 使用scp命令报错: [root@oradb23 media]# scp /etc/hosts oradb24:/etc/ -bash: scp: command not fou ...

  6. source /etc/profile报错-bash: id:command is not found

    由于误操作导致 source /etc/profile 报错 -bash: id:command is not found 此时,linux下很多命令到不能能用,包括vi ls 等... 可以使用 e ...

  7. -bash: .bash_profile: command not found

    今天有一同事安装了ORACLE后,在切换账号时遇到错误提示"-bash: .bash_profile: command not found".如下所示 [root@GLETestL ...

  8. Linux下提示 bash: xxx command not found

    今天在虚拟机上安装了CentOS5.5,发现运行一些很正常的诸如:init,shutdown,fdisk 等命令时,悍然提示: bash: xxx command not found. 那么,首先就要 ...

  9. [原创]-bash: iostat: command not found解决办法

    [root@testhost ~]# iostat-bash: iostat: command not found IOSTAT 命令不可用,首先确认sysstat包是否安装,sysstat包中包括i ...

随机推荐

  1. uboot中fdt命令的使用

    转载:https://blog.csdn.net/voice_shen/article/details/7441894 依linux community的要求,从linux-3.5后,新提交的code ...

  2. FDR错误发现率-P值校正学习[转载]

    转自:https://baike.baidu.com/item/FDR/16312044?fr=aladdin  https://blog.csdn.net/taojiea1014/article/d ...

  3. X-Forwarded-For 负载均衡 7 层 HTTP 模式获取来访客户端真实 IP 的方法(IIS/Apache/Nginx/Tomcat)

    https://help.aliyun.com/knowledge_detail/13051859.html?pos=1 1.IIS 6 配置方案2.IIS 7 配置方案3.Apache 配置方案4. ...

  4. 2018-2019-2 20165209 《网络对抗技术》Exp6:信息搜集与漏洞扫描

    2018-2019-2 20165209 <网络对抗技术>Exp6:信息搜集与漏洞扫描 1 基础问题回答和实验内容 1.1基础问题回答 (1)哪些组织负责DNS,IP的管理. Intern ...

  5. ThinkPHP问题收集:模板中使用U方法时无法嵌套大括号,For标签,插入数据,新增的表字段缓存问题

    ThinkPHP模板中使用U方法时无法嵌套大括号需要在control里面用U方法赋值给变量传到模版如:{:U('/Blog/comment/',array('id'=>$id)}$comment ...

  6. sql server deadlock跟踪的四种方法

    最近写程序常会遇到deadlock victim,每次一脸懵逼.研究了下怎么跟踪,写下来记录下. 建测试数据 CREATE DATABASE testdb; GO USE testdb; CREATE ...

  7. I/O复习

    I/O流之字符流 问题:字节流和字符流区别? java1.0只提供了字节流,分为输出流(Inputstream)和输入流(Outputstream), 以字节为单位来读取或写入数据,以二进制来处理数据 ...

  8. kafka-python的API简单介绍

    在上一篇文章中说明了kafka-python的API使用的理论概念,这篇文章来说明API的实际使用. 在官方文档详细列出了kafka-python的API接口https://kafka-python. ...

  9. this逃逸

    首先,什么是this逃逸? this逃逸是指类构造函数在返回实例之前,线程便持有该对象的引用. 常发生于在构造函数中启动线程或注册监听器. eg: public class ThisEscape { ...

  10. 20145304 Exp8 Web基础

    20145304 Exp8 Web基础 实验后回答问题 (1)什么是表单 表单用于搜集不同类型的用户输入,由三个基本组成部分表单标签.表单域.表单按钮.表单提交有两种方法,分别是get和post,使用 ...