通过npm全局安装的软件包在cmd中不可见

时间:2018-06-20 07:39:45

标签: node.js npm polymer ubuntu-18.04

$ npm install -g polymer-cli
/home/kishore/.npm-global/bin/polymer -> /home/kishore/.npm-global/lib/node_modules/polymer-cli/bin/polymer.js
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/polymer-cli/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

+ polymer-cli@1.7.4
updated 1 package in 8.834s
$ polymer --version
polymer: command not found

1 个答案:

答案 0 :(得分:1)

我指定了$ PATH到安装全局软件包的目录的路径!