0

I followed the instructions: http://learnsemantic.com/guide/expert.html

And I got to the point where I should run this command:

npm install -g gulp

I get the following result:

npm ERR!      'Object.oncomplete (fs.js:107:15)' ] }
npm ERR! 
npm ERR! Please try running this command again as root/Administrator.

npm ERR! System Linux 3.19.0-16-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install" "-g" "gulp"
npm ERR! cwd /home/yannick
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.4.21
npm ERR! path /usr/local/lib/node_modules
npm ERR! fstream_path /usr/local/lib/node_modules/gulp
npm ERR! fstream_type Directory
npm ERR! fstream_class DirWriter
npm ERR! code EACCES
npm ERR! errno 3
npm ERR! stack Error: EACCES, mkdir '/usr/local/lib/node_modules'
npm ERR! fstream_stack /usr/lib/nodejs/fstream/lib/writer.js:171:23
npm ERR! fstream_stack /usr/lib/nodejs/mkdirp/index.js:46:53
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /home/yannick/npm-debug.log
npm ERR! not ok code 0

Can anyone tell me what I am doing wrong?

2 Answers 2

1

Solved! The answer can be found here: https://github.com/joyent/node/issues/3911#issuecomment-8956154

:)

Sign up to request clarification or add additional context in comments.

Comments

0

The key is line 3,

npm ERR! Please try running this command again as root/Administrator.

Try running the command as a sudo user or even better make sure that you can install npm modules globally without needing the sudo command. The guide I last used can be found is here: https://github.com/sindresorhus/guides/blob/master/npm-global-without-sudo.md

5 Comments

thank you. Why exactly shouldnt I use sudo command tho? I read this quite often. I just tried to run it as: sudo npm install -g gulp but I cant run "gulp" in the terminal. It simply tells me that gulp not found.. hm?
It is generally considered bad practise to have to use sudo with npm, with regard to the other error I'm not sure, but it could be an issue with the permissions of the install of node/npm the article has fairly explicit instructions on how to install both without sudo so I would maybe try uninstalling node/npm and trying again
alright. Thank you. I deinstalled node/npm and did the following steps: 1.Installed Semantic UI, 2.Installing Node like shown in the instructions. 3.installing npm like it shows in your link 4. now when i try to call "gulp" nothnig happens and it shows me "no such file or directory" ... ?
Seems to be some suggestions about needing to install it in your project too npm install gulp --save-dev, maybe give that a go
I tried this, but it didnt change anything. There is a gulp folder in the node_modules folder tho. Weird. I am something missing..but idk what :/

Your Answer

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.