Questions tagged [npm-cli]
30 questions
85
votes
6 answers
list all globally installed modules with one command in ubuntu
I'm working on ubuntu 14.04, Is there any way to print all global modules (installed using npm) to the command line. How can I do this?

Muhsin Keloth
- 7,855
- 7
- 39
- 59
53
votes
3 answers
Are there npm version prerelease identifiers?
There is a very handy npm version command. Besides arguments like major, minor and patch it accepts arguments like prerelease, prepatch, etc.
It says in the docs that the commands work in accordance with the semver.inc function.
These pre commands I…

timetowonder
- 5,121
- 5
- 34
- 48
21
votes
2 answers
How do I resolve npm audit returning ENOAUDIT: Your configured registry does not support audit requests?
This recently broke and I do not know what I might have done to break it beyond adding some additional dependencies. I am using https://registry.npmjs.org/ (the default). The relevant portion of the log file is below. Has anyone seen something…

ChiralMichael
- 1,214
- 9
- 20
20
votes
7 answers
how to run node / babel script directly in command line?
My package.json looks like:
{
"name": "99-nodetest",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"start": "babel-node --presets env app.js"
},
…

joedotnot
- 4,810
- 8
- 59
- 91
13
votes
1 answer
NPM - Questions about `Email: (this IS public)`
I've configured the email address on npmjs.com, why does the cli keep prompting me to enter email?
$ npm login
npm notice Log in on https://registry.npmjs.org/
Username: wenfangdu
Password:
Email: (this IS public)
Even if I enter a wrong email that…

Wenfang Du
- 8,804
- 9
- 59
- 90
7
votes
1 answer
NPM outdated command not showing full list
When I do on my terminal:
npm outdated -g
I get a list of global packages that have updates available, and that's fine:
Package Current Wanted Latest Location
create-next-app 10.0.3 10.0.4 10.0.4 global
eslint-plugin-react …

Or Assayag
- 5,662
- 13
- 57
- 93
4
votes
1 answer
npm 8.5.5: unexected token in @npmcli\arborist
after upgrading npm (via nvm) to 8.5.5 npm commands do not work anymore:
e.g. npm --verbose ls webpack fails with:
npm verb stack C:\Users\marti\AppData\Roaming\nvm\v16.15.0\node_modules\npm\node_modules\@npmcli\arborist:1
npm verb stack…

TmTron
- 17,012
- 10
- 94
- 142
2
votes
0 answers
Why NPM CLI creates two identical tokens?
I was trying the NPM cli and I ran 2 times the command npm create token --read-only after having logged in. The result is that now I have 2 completely identical tokens that I'm not able to manage, neither delete, since the CLI replies with a Token…

Ale TheFe
- 1,540
- 15
- 43
2
votes
0 answers
Where NPM Install output goes? I cannot find it in stdout nor stderr
I am trying to get the output of the command npm install and show it in my cli module.
But I am getting only the result at the end, not the loading output with the progress bar.
Is maybe npm outputing in another place different from stdout and…

47ndr
- 583
- 5
- 23
1
vote
1 answer
npm v9.4.0 is known not to run on Node.js v19.5.0
I somehow broke npm on my Windows system. Any (literally any) npm command I use gives me the following illogical error:
ERROR: npm v9.4.0 is known not to run on Node.js v19.5.0. You'll need to upgrade to a newer Node.js version in order to use this…

user2447067
- 31
- 2
1
vote
1 answer
NPM login to GitHub registry requires lowercase username
I'm trying to log in from the command line using this command:
$ npm login --registry=https://npm.pkg.github.com/
But my username on GitHub has an uppercase first letter, which results in the following error:
$ npm login…

o01
- 5,191
- 10
- 44
- 85
1
vote
1 answer
I got path error : [module not found] whenever I try to run any npm related command in VS Code
Whenever I try to run any npm related command such as npm -v or npm install , it gives me the error:
From the screenshot, you can see that it is trying to navigate to find the module but the module can not be found at:
C:\Program…

Ibad Shaikh
- 2,704
- 3
- 15
- 27
1
vote
2 answers
Unable to install npx create-react-app@3.3.0 nucampsite
As instructed by my school, I was trying to install "npx create-react-app@3.3.0 nucampsite" but it opens up visual studio code with the file npm-cli.js
I tried running the command from Visual Studio Code and I got this error…

Jay Pirani
- 11
- 2
1
vote
2 answers
Good way to install exact dependency globally
For the Node.js world, we can use NVM to switch between Node.js versions, and also switch out which global packages are in scope (in the $PATH).
However, what if I want to ensure that I use typescript version 3.3.334 at the command line? Obviously,…

Alexander Mills
- 90,741
- 139
- 482
- 817
1
vote
2 answers
Error installing Express via nodejs
I'm trying to install express via nodeJS and the errors that I am getting tell me that I should rename my directories. I have already run npm init in my project folder so I assume the setup is correct. The exact command that I use is: npm install…

Nayman Leung
- 21
- 4