0

I just want to edit some files on staging server. How can i install grunt on staging server.?

I have run this command:

npm install -g grunt-cli

error showing that npm: command not found

How can i install grunt on staging server.?

Thanks.!

2 Answers 2

0

This depends on your server setup, instructions for different servers can be found on https://nodejs.org/en/download/package-manager

For the sites I work on this works:

curl --silent --location https://rpm.nodesource.com/setup_4.x | bash - 

That is not the latest version, for the latest check the link above.

Then navigate to the directory of your packages.json and run

npm install

From there you should be able to follow the instructions here (dev docs).

0

Install nodejs, npm, and grunt-cli¶

$ sudo add-apt-repository ppa:chris-lea/node.js 
$ sudo apt-get update 
$ sudo apt-get install nodejs 
$ sudo npm install -g grunt-cli `enter code here`

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.