无法将Bower识别为内部或外部命令 [英] Bower is not recognized as internal or external command

查看:276
本文介绍了无法将Bower识别为内部或外部命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道这个问题已经问过很多遍了,但实际上没有一个人帮助过我。
我在Windows 10上,并且已经使用以下代码通过npm成功安装了bower

I know the question has been asked many times but really none of them helped me. I'm on windows 10 and have successfully installed bower via npm using the following code

npm install -g bower

我已经添加了系统环境变量的路径,但是仍然得到相同的错误信息b不被识别为内部或外部命令。

I've added the path to system environment variable but still getting the same error bower is not recognized as internal or external command.

我已将以下路径添加到系统环境变量中

I've added the following path into my system environment variable

C:\Users\habib\AppData\Romaing\npm

当我尝试

  npm config get prefix
 C:\Users\habib\AppData\Romaing\npm

当我尝试

npm bower -v

我得到了Bower版本

I get the bower version

也对此进行了尝试

他们都不为我工作。

为什么会这样?

推荐答案

我尝试将用户环境变量中的路径变量值设置为与系统环境变量相同,并且有效...

I've tried set the Path variable value in Users Environment variable to the same as for System Environment variable and it worked...

C:\Users\<username>\AppData\Roaming\npm

这篇关于无法将Bower识别为内部或外部命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆