Questions tagged [npm-cli]

21 questions
71
votes
5 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,076
  • 6
  • 33
  • 57
31
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
  • 4,151
  • 3
  • 27
  • 41
20
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,148
  • 7
  • 19
15
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,295
  • 6
  • 49
  • 76
5
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
  • 3,141
  • 8
  • 30
  • 52
1
vote
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
  • 1,884
  • 3
  • 14
  • 33
1
vote
0 answers

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
  • 192
  • 2
  • 11
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
  • 1
  • 80
  • 344
  • 642
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…
1
vote
1 answer

Node-sass creates extra files in watch mode

I import all my SCSS styles into a index.scss file using @import. This works fine when I build css manually using npm run build-css: "scripts": { //Other scripts "build-css": "node-sass src/scss/index.scss -o dist/css/", } When I run…
JSNinja
  • 695
  • 5
  • 19
0
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…
ndr4
  • 107
  • 8
0
votes
1 answer

node js cli STDOUT STDERR output exec and spawn commands

I am looking for a clear answer on how the stdout and stderr work when developing a npm cli module. I would like to print out everything exactly as it is when I run command with child_process.spawn. I managed to output the git clone command with the…
ndr4
  • 107
  • 8
0
votes
1 answer

Docker is "too verbose" in npm-cli-adduser

When my Dockerfile does the RUN command: RUN npm-cli-adduser -r https://$PRIVATE_REPOSITORY_URL/repository/npm-read -u $PRIVATE_USERNAME -p "$PRIVATE_PASSWORD" -e service-foobar@example.com It echos the private environment variables in the terminal.…
sheepiiHD
  • 392
  • 1
  • 14
0
votes
0 answers

Your global Angular CLI version (11.0.5) is greater than your local version (1.1.0). The local Angular CLI version is used

After applying the npm install --save-dev @angular/cli@latest command my local CLI version got upgraded to (11.0.5), But again I am getting this error An unhandled exception occurred: No projects support the 'serve' target. See…
1
2