cgross / generator-cg-angular

Yeoman generator for Enterprise Angular projects.
MIT License
592 stars 198 forks source link

Errors with yo cg-angular #61

Closed ghost closed 10 years ago

ghost commented 10 years ago

I'm following your example and get errors from the start. Was wondering if you could help me out with these? I have installed yeoman and used it for the regular angular generators without issues.

Here are my steps:

1) sudo npm install -g grunt-cli yo bower 2) sudo npm install -g generator-cg-angular 3) mkdir MyNewAwesomeApp 4) cd MyNewAwesomeApp 5) yo cg-angular

bower angular#>= 1.0.8 cached git://github.com/angular/bower-angular.git#1.2.24 bower angular#>= 1.0.8 validate 1.2.24 against git://github.com/angular/bower-angular.git#>= 1.0.8 bower angular#>=1 cached git://github.com/angular/bower-angular.git#1.2.24 bower angular#>=1 validate 1.2.24 against git://github.com/angular/bower-angular.git#>=1 bower angular#>= 1.0.2 cached git://github.com/angular/bower-angular.git#1.2.24 bower angular#>= 1.0.2 validate 1.2.24 against git://github.com/angular/bower-angular.git#>= 1.0.2 npm WARN deprecated ngmin@0.4.1: use ng-annotate instead npm ERR! Error: EACCES, mkdir '/Users/des/.npm/adm-zip/0.2.1' npm ERR! { [Error: EACCES, mkdir '/Users/des/.npm/adm-zip/0.2.1'] npm ERR! errno: 3, npm ERR! code: 'EACCES', npm ERR! path: '/Users/des/.npm/adm-zip/0.2.1', npm ERR! parent: 'phantomjs' } npm ERR! npm ERR! Please try running this command again as root/Administrator. npm ERR! System Darwin 13.3.0 npm ERR! command "node" "/usr/local/bin/npm" "install" npm ERR! cwd /Users/des/Sites/JavaScript/AngularJS/MyNewAwesomeApp npm ERR! node -v v0.10.30 npm ERR! npm -v 1.4.21 npm ERR! path /Users/des/.npm/adm-zip/0.2.1 npm ERR! code EACCES npm ERR! errno 3 npm ERR! stack Error: EACCES, mkdir '/Users/des/.npm/adm-zip/0.2.1' bower angular-ui-router#~0.2 install angular-ui-router#0.2.11 bower moment#~2.5 install moment#2.5.1 Further down I also hit this error... bower font-awesome#~4.0 progress received 0.9MB of 1.8MB downloaded, 49% bower angular#~1.2 invalid-meta angular is missing "ignore" entry in bower.json bower angular#~1.2 resolved git://github.com/angular/bower-angular.git#1.2.24 SOLINK_MODULE(target) Release/validation.node SOLINK_MODULE(target) Release/validation.node: Finished npm ERR! git clone git@github.com:pipobscure/fsevents Cloning into bare repository '/Users/des/.npm/_git-remotes/git-github-com-pipobscure-fsevents-2ef85406'... npm ERR! git clone git@github.com:pipobscure/fsevents Warning: Permanently added the RSA host key for IP address '192.30.252.131' to the list of known hosts. npm ERR! git clone git@github.com:pipobscure/fsevents Permission denied (publickey). npm ERR! git clone git@github.com:pipobscure/fsevents fatal: Could not read from remote repository. npm ERR! git clone git@github.com:pipobscure/fsevents npm ERR! git clone git@github.com:pipobscure/fsevents Please make sure you have the correct access rights npm ERR! git clone git@github.com:pipobscure/fsevents and the repository exists. npm WARN optional dep failed, continuing fsevents@pipobscure/fsevents#7dcdf9fa3f8956610fd6f69f72c67bace2de7138 bower angular-ui-router#~0.2 progress received 1.1MB of 1.4MB downloaded, 80% bower font-awesome#~4.0 progress received 0.9MB of 1.8MB downloaded, 50% Does not seem to work after this. I also tried sudo yo cg-angular, but the same. I create the directory manually, but then it needs the next one with same error. Thanks Des
bwinchester commented 10 years ago

Quote: 1) sudo npm install -g grunt-cli yo bower 2) sudo npm install -g generator-cg-angular

I don't think you are supposed to sudo install npm modules like that. It will likely make it read/write only from admin level and is probably why everything isn't working. retry without sudo.

adnasa commented 10 years ago

@deshartman Is this still an issue? please close if it isn't

LegalizeAdulthood commented 10 years ago

I've installed the modules with sudo on an Ubuntu distribution and had no problems. npm install -g wants to install to the global location. If you try it without sudo, then you must already have permissions to write to the global location, which you are unlikely to have as an ordinary user.

rafialikhan commented 10 years ago

This is a problem with installing this on windows as well.

Steps:

  1. npm install -g generator-cg-angular
  2. Went to the respective folder where i want it installed
  3. yo cd-angular
  4. Error cg-angular (You don't seem to have a generator with the name cg-angular installed)

Retried the whole thing again, same error.

tapas4java commented 10 years ago

yo cd-angular?? Is it a typo?

adnasa commented 10 years ago

@tapas4java +1

ghost commented 10 years ago

Sorry, have not had time to look at this. Will close for now

ghost commented 10 years ago

PS. Yes, that is a typo

rafialikhan commented 10 years ago

Yes its a typo. Its yo cg-angular (coz i typed it in)

But the problem is that even though its installed globally, it kept saying cg-angular does not exist. If this is solved, would like to know if its working for people on windows.

tapas4java commented 10 years ago

Can you check below location weather generator-cg-angular folder is present?

C:\Users\[user]\AppData\Roaming\npm\node_modules