npm审核不起作用,并且未列出依赖项的描述

时间:2018-12-05 21:21:13

标签: node.js npm

我给出npm audit命令,但是没有列出相关性的描述。它在终端上给出以下输出

Usage: npm <command>

where <command> is one of:
    access, add-user, adduser, apihelp, author, bin, bugs, c,
    cache, completion, config, ddp, dedupe, deprecate, dist-tag,
    dist-tags, docs, edit, explore, faq, find, find-dupes, get,
    help, help-search, home, i, info, init, install,
    install-test, issues, it, la, link, list, ll, ln, login,
    logout, ls, outdated, owner, pack, ping, prefix, prune,
    publish, r, rb, rebuild, remove, repo, restart, rm, root,
    run-script, s, se, search, set, show, shrinkwrap, star,
    stars, start, stop, t, tag, team, test, tst, un, uninstall,
    unlink, unpublish, unstar, up, update, upgrade, v, verison,
    version, view, whoami

npm <cmd> -h     quick help on <cmd>
npm -l           display full usage info
npm faq          commonly asked questions
npm help <term>  search for help on <term>
npm help npm     involved overview

Specify configs in the ini-formatted file:
    /home/devendra/.npmrc
or on the command line via: npm <command> --key value
Config info can be viewed via: npm help config

npm@3.5.2 /usr/share/npm

任何想法,我在这里缺少什么!

谢谢

1 个答案:

答案 0 :(得分:0)

因此解决方案是升级到较新的npm版本(请参阅注释)。

以防万一其他人在Ubuntu上遇到相同的问题:

Bash兑现了npm命令的路径,您必须在使用新版本之前清除bash缓存。详细说明: https://askubuntu.com/questions/1036278/npm-is-incorrect-version-on-latest-ubuntu-18-04-installation?rq=1