Closed NomiJ closed 9 years ago
@NomiJ, you are running the generator command using sudo
?
Take a look at http://howtonode.org/introduction-to-npm
I tried without sudo earlier, It gave the same output as with sudo. Thanks for the link, manually trying "sudo npm install" worked for me
Okay, but that may not be a long term solution. Because you have to see the generator fail every time and then explicitly run sudo npm install
.
So what is the long term solution? I just tried to follow the instructions from
@NomiJ The Instructions on my blog are only for installing the generator. I have not provided any info on how to setup NPM.
The issue here is that all the global packages you have installed, have been installed with a sudo
since you do not have permission to the global npm
folder.
The recommendation is to uninstall node/npm and install it again and this time, you need to set permissions to the global npm
folder. Once that is done, you can install global packages without a sudo
.
And then on you would not need sudo
while managing npm packages.
Thanks.
Thank @arvindr21 for going beyond to help, figure and sort the actual issue.
NP! Glad I could be of help!
MacBook-Air:soh n$ sudo yo framework7-phonegap
---------´ | Framework7Phonegap | ( _´U
_ ) | generator! | /_A\ '--------------------------' | ~ |**'.**.'__
´
|° ´ Y
? What is the name of your app? soh identical hooks/README.md identical www/res/icon/android/icon-36-ldpi.png ...... ..... identical framework7/.jshintrc
I'm all done. Running bower install & npm install for you to install the required dependencies. If this fails, try running the command yourself.
npm WARN package.json soh@0.0.1 No description npm WARN package.json soh@0.0.1 No repository field. npm WARN package.json soh@0.0.1 No README data npm ERR! Error: EACCES, mkdir '/Users/nomi/tmp/npm-22791-wFi75y28' npm ERR! { [Error: EACCES, mkdir '/Users/nomi/tmp/npm-22791-wFi75y28'] npm ERR! errno: 3, npm ERR! code: 'EACCES', npm ERR! path: '/Users/nomi/tmp/npm-22791-wFi75y28', npm ERR! parent: 'soh' } npm ERR! npm ERR! Please try running this command again as root/Administrator.
npm ERR! System Darwin 14.0.0 npm ERR! command "node" "/usr/local/bin/npm" "install" npm ERR! cwd /Users/nomi/Documents/SystematicBytes/DrunkApps/soh npm ERR! node -v v0.10.29 npm ERR! npm -v 1.4.14 npm ERR! path /Users/nomi/tmp/npm-22791-wFi75y28 npm ERR! code EACCES npm ERR! errno 3 npm ERR! stack Error: EACCES, mkdir '/Users/nomi/tmp/npm-22791-wFi75y28' npm ERR! npm ERR! Additional logging details can be found in: npm ERR! /Users/nomi/Documents/SystematicBytes/DrunkApps/soh/npm-debug.log npm ERR! not ok code 0