Reputation: 799
I have installed mean.io through npm. I have updated node, grunt, bower and have used mean init to create my project.
I then cd into the project directory and "sudo npm install".
I now try running grunt and receive an error
Error: Cannot find module 'meanio'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)
Can someone explain why this is happening? Have I installed mean.io incorrectly?
Upvotes: 0
Views: 81
Reputation: 294
You should not run thr npm install as root. All of the installtion is as a normal user excluding the
sudo initial npm install -g mean-cli
If you still have problems chown all you directory to -
chown -R youUser *
You might still have permissions as root at ~/.npm - so examine that and chown there as well.
Upvotes: 0