Cannot install ionic on my mac using the node.js


#1

The following is the error message that I received from the termini, kindly assist:

Haryonos-MacBook-Pro:~ haryonoyeo$ npm install -g cordova ionic
npm ERR! Error: EACCES, mkdir '/usr/local/lib/node_modules/cordova’
npm ERR! { [Error: EACCES, mkdir ‘/usr/local/lib/node_modules/cordova’]
npm ERR! errno: 3,
npm ERR! code: ‘EACCES’,
npm ERR! path: ‘/usr/local/lib/node_modules/cordova’,
npm ERR! fstream_type: ‘Directory’,
npm ERR! fstream_path: ‘/usr/local/lib/node_modules/cordova’,
npm ERR! fstream_class: ‘DirWriter’,
npm ERR! fstream_stack:
npm ERR! [ ‘/usr/local/lib/node_modules/npm/node_modules/fstream/lib/dir-writer.js:36:23’,
npm ERR! ‘/usr/local/lib/node_modules/npm/node_modules/mkdirp/index.js:46:53’,
npm ERR! ‘Object.oncomplete (fs.js:107:15)’ ] }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.

npm ERR! System Darwin 13.4.0
npm ERR! command “node” “/usr/local/bin/npm” “install” “-g” “cordova” "ionic"
npm ERR! cwd /Users/haryonoyeo
npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! path /usr/local/lib/node_modules/cordova
npm ERR! fstream_path /usr/local/lib/node_modules/cordova
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/cordova’
npm ERR! fstream_stack /usr/local/lib/node_modules/npm/node_modules/fstream/lib/dir-writer.js:36:23
npm ERR! fstream_stack /usr/local/lib/node_modules/npm/node_modules/mkdirp/index.js:46:53
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! Error: EACCES, mkdir '/usr/local/lib/node_modules/ionic’
npm ERR! { [Error: EACCES, mkdir ‘/usr/local/lib/node_modules/ionic’]
npm ERR! errno: 3,
npm ERR! code: ‘EACCES’,
npm ERR! path: ‘/usr/local/lib/node_modules/ionic’,
npm ERR! fstream_type: ‘Directory’,
npm ERR! fstream_path: ‘/usr/local/lib/node_modules/ionic’,
npm ERR! fstream_class: ‘DirWriter’,
npm ERR! fstream_stack:
npm ERR! [ ‘/usr/local/lib/node_modules/npm/node_modules/fstream/lib/dir-writer.js:36:23’,
npm ERR! ‘/usr/local/lib/node_modules/npm/node_modules/mkdirp/index.js:46:53’,
npm ERR! ‘Object.oncomplete (fs.js:107:15)’ ] }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.

npm ERR! System Darwin 13.4.0
npm ERR! command “node” “/usr/local/bin/npm” “install” “-g” “cordova” "ionic"
npm ERR! cwd /Users/haryonoyeo
npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! path /usr/local/lib/node_modules/ionic
npm ERR! fstream_path /usr/local/lib/node_modules/ionic
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/ionic’
npm ERR! fstream_stack /usr/local/lib/node_modules/npm/node_modules/fstream/lib/dir-writer.js:36:23
npm ERR! fstream_stack /usr/local/lib/node_modules/npm/node_modules/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! /Users/haryonoyeo/npm-debug.log
npm ERR! not ok code 0


Npm install -g cordova ionic Error
#2

I have solved the following problem by placing :
sudo npm install -g cordova ionic

Kindly close the ticket =)


#3

I am getting below error:

Macs-MacBook-Pro:~ mac$ sudo npm install -g cordova ionic
Password:
npm ERR! registry error parsing json
^CMacs-MacBook-Pro:~ mac$ sudo npm install -g ionic cordova
Password:
npm WARN engine cordova-js@3.8.0: wanted: {“node”:"~0.10.x"} (current: {“node”:“0.12.1”,“npm”:“2.5.1”})
npm WARN engine npm@1.3.4: wanted: {“node”:">=0.6",“npm”:“1”} (current: {“node”:“0.12.1”,“npm”:“2.5.1”})
npm WARN engine xmlbuilder@2.2.1: wanted: {“node”:“0.8.x || 0.10.x”} (current: {“node”:“0.12.1”,“npm”:“2.5.1”})
/usr/local/bin/cordova -> /usr/local/lib/node_modules/cordova/bin/cordova
npm ERR! cb() never called!


#4

Hi guys,

Been trying to solve an issue with installing ionic and I got led to here. Seems to be a similar if not same issue:

Chintans-MacBook-Pro:~ csutaria$ npm install -g cordova ionic

This is the result:

npm ERR! tar.unpack untar error /Users/csutaria/.npm/ionic/1.4.5/package.tgz
npm ERR! Darwin 14.3.0
npm ERR! argv "node" "/usr/local/bin/npm" "install" "-g" "cordova" "ionic"
npm ERR! node v0.12.2
npm ERR! npm  v2.7.4
npm ERR! path /usr/local/lib/node_modules/ionic
npm ERR! code EACCES
npm ERR! errno -13

npm ERR! Error: EACCES, mkdir '/usr/local/lib/node_modules/ionic'
npm ERR!     at Error (native)
npm ERR!  { [Error: EACCES, mkdir '/usr/local/lib/node_modules/ionic']
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   path: '/usr/local/lib/node_modules/ionic',
npm ERR!   fstream_type: 'Directory',
npm ERR!   fstream_path: '/usr/local/lib/node_modules/ionic',
npm ERR!   fstream_class: 'DirWriter',
npm ERR!   fstream_stack: 
npm ERR!    [ '/usr/local/lib/node_modules/npm/node_modules/fstream/lib/dir-writer.js:36:23',
npm ERR!      '/usr/local/lib/node_modules/npm/node_modules/mkdirp/index.js:46:53',
npm ERR!      'FSReqWrap.oncomplete (fs.js:95:15)' ] }
npm ERR! 
npm ERR! Please try running this command again as root/Administrator.
npm ERR! error rolling back Error: EACCES, rmdir '/usr/local/lib/node_modules/cordova'
npm ERR! error rolling back     at Error (native)
npm ERR! error rolling back  { [Error: EACCES, rmdir '/usr/local/lib/node_modules/cordova']
npm ERR! error rolling back   errno: -13,
npm ERR! error rolling back   code: 'EACCES',
npm ERR! error rolling back   path: '/usr/local/lib/node_modules/cordova' }

npm ERR! Please include the following file with any support request:
npm ERR!     /Users/csutaria/npm-debug.log

And this is the debug log:

 info it worked if it ends with ok

44 silly addNameRange     '0.1.9',
44 silly addNameRange     '0.1.10',
44 silly addNameRange     '0.1.11',
44 silly addNameRange     '0.1.12',
44 silly addNameRange     '0.1.13',
44 silly addNameRange     '0.1.14',
44 silly addNameRange     '2.2.0',
44 silly addNameRange     '2.3.0',
44 silly addNameRange     '2.3.1',
44 silly addNameRange     '2.3.2',
44 silly addNameRange     '2.3.3',
44 silly addNameRange     '2.3.5',
44 silly addNameRange     '2.3.6',
44 silly addNameRange     '2.4.0',
44 silly addNameRange     '2.4.1',
44 silly addNameRange     '2.4.2',
44 silly addNameRange     '2.4.3',
44 silly addNameRange     '2.4.4',
44 silly addNameRange     '2.4.5',
44 silly addNameRange     '2.4.6',
44 silly addNameRange     '2.4.7',
44 silly addNameRange     '2.4.8',
44 silly addNameRange     '2.4.9',
44 silly addNameRange     '2.4.10',
44 silly addNameRange     '2.5.0',
44 silly addNameRange     '2.5.2',
44 silly addNameRange     '2.5.3',
44 silly addNameRange     '2.5.4',
44 silly addNameRange     '2.5.5',
44 silly addNameRange     '2.6.0',
44 silly addNameRange     '2.6.1',
44 silly addNameRange     '2.6.2',
44 silly addNameRange     '2.7.0-rc.1',
44 silly addNameRange     '2.7.1-rc.1',
44 silly addNameRange     '2.7.2',
44 silly addNameRange     '2.7.3',
44 silly addNameRange     '2.7.4',
44 silly addNameRange     '2.8.0',
44 silly addNameRange     '2.8.1',
44 silly addNameRange     '2.8.2',
44 silly addNameRange     '2.8.3',
44 silly addNameRange     '2.8.4',
44 silly addNameRange     '2.8.5',
44 silly addNameRange     '2.8.6',
44 silly addNameRange     '2.8.7',
44 silly addNameRange     '2.8.8',
44 silly addNameRange     '2.8.9',
44 silly addNameRange     '2.8.10',
44 silly addNameRange     '2.8.11',
44 silly addNameRange     '2.8.12',
44 silly addNameRange     '2.8.13',
44 silly addNameRange     '2.8.14',
44 silly addNameRange     '2.8.15',
44 silly addNameRange     '2.8.16',
44 silly addNameRange     '2.8.17',
44 silly addNameRange     '2.8.18',
44 silly addNameRange     '2.8.19',
44 silly addNameRange     '2.8.20',
44 silly addNameRange     '2.8.21',
44 silly addNameRange     '2.8.22',
44 silly addNameRange     '2.8.23',
44 silly addNameRange     '2.8.24',
44 silly addNameRange     '2.8.25',
44 silly addNameRange     '2.9.0',
44 silly addNameRange     '2.9.1',
44 silly addNameRange     '2.9.2',
44 silly addNameRange     '2.9.3',
44 silly addNameRange     '2.9.4',
44 silly addNameRange     '2.9.5',
44 silly addNameRange     '2.9.6',
44 silly addNameRange     '2.9.7',
44 silly addNameRange     '3.0.0-rc1',
44 silly addNameRange     '3.0.0-rc1-1',
44 silly addNameRange     '3.0.0-rc1-3',
44 silly addNameRange     '3.0.0',
44 silly addNameRange     '3.0.1',
44 silly addNameRange     '3.0.2',
44 silly addNameRange     '3.0.3',
44 silly addNameRange     '3.0.4',
44 silly addNameRange     '3.0.5',
44 silly addNameRange     '3.0.6',
44 silly addNameRange     '3.0.7',
44 silly addNameRange     '3.0.8',
44 silly addNameRange     '3.0.9',
44 silly addNameRange     '3.0.10',
44 silly addNameRange     '3.1.0-0.1.0',
44 silly addNameRange     '3.1.0-0.2.0',
44 silly addNameRange     '3.2.0-rc.1',
44 silly addNameRange     '3.2.0-0.1.0',
44 silly addNameRange     '3.2.0-0.2.0',
44 silly addNameRange     '3.2.0-0.3.0',
44 silly addNameRange     '3.2.0-0.4.0',
44 silly addNameRange     '3.3.0-rc.1',
44 silly addNameRange     '3.3.0-0.1.1',
44 silly addNameRange     '3.3.1-0.1.2',
44 silly addNameRange     '2.9.0-rc1',
44 silly addNameRange     '3.3.1-0.3.0',
44 silly addNameRange     '3.3.1-0.3.1',
44 silly addNameRange     '3.3.1-0.4.1',
44 silly addNameRange     '3.3.1-0.4.2',
44 silly addNameRange     '3.4.0-0.1.0',
44 silly addNameRange     '3.4.0-0.1.1',
44 silly addNameRange     '3.4.0-0.1.2',
44 silly addNameRange     '3.4.0-0.1.3',
44 silly addNameRange     '0.0.0-fake',
44 silly addNameRange     '3.4.1-0.1.0',
44 silly addNameRange     '3.5.0-0.2.0',
44 silly addNameRange     '3.5.0-0.2.1',
44 silly addNameRange     '3.5.0-0.2.2',
44 silly addNameRange     '3.5.0-0.2.3',
44 silly addNameRange     '3.5.0-0.2.4',
44 silly addNameRange     '3.5.0-0.2.6',
44 silly addNameRange     '3.5.0-0.2.7',
44 silly addNameRange     '3.6.0-0.2.8',
44 silly addNameRange     '3.6.0-0.2.9',
44 silly addNameRange     '3.6.1-0.2.10',
44 silly addNameRange     '3.6.3-0.2.11',
44 silly addNameRange     '3.6.3-0.2.12',
44 silly addNameRange     '3.6.3-0.2.13',
44 silly addNameRange     '4.0.0',
44 silly addNameRange     '4.0.1',
44 silly addNameRange     '4.1.0',
44 silly addNameRange     '4.1.1',
44 silly addNameRange     '4.1.2',
44 silly addNameRange     '4.1.3-nightly.2014.10.21',
44 silly addNameRange     '4.2.0',
44 silly addNameRange     '4.3.0',
44 silly addNameRange     '5.0.0' ] ]
45 verbose addNamed cordova@5.0.0
46 silly addNamed semver.valid 5.0.0
47 silly addNamed semver.validRange 5.0.0
48 silly cache afterAdd cordova@5.0.0
49 verbose afterAdd /Users/csutaria/.npm/cordova/5.0.0/package/package.json not in flight; writing
50 verbose afterAdd /Users/csutaria/.npm/cordova/5.0.0/package/package.json written
51 http 304 https://registry.npmjs.org/ionic
52 silly get cb [ 304,
52 silly get   { date: 'Fri, 22 May 2015 23:53:55 GMT',
52 silly get     via: '1.1 varnish',
52 silly get     'cache-control': 'max-age=60',
52 silly get     etag: '"95IYCZVBX032NQI1TP8RY7S1D"',
52 silly get     age: '0',
52 silly get     connection: 'keep-alive',
52 silly get     'x-served-by': 'cache-dfw1835-DFW',
52 silly get     'x-cache': 'MISS',
52 silly get     'x-cache-hits': '0',
52 silly get     'x-timer': 'S1432338835.355151,VS0,VE186',
52 silly get     vary: 'Accept' } ]
53 verbose etag https://registry.npmjs.org/ionic from cache
54 verbose get saving ionic to /Users/csutaria/.npm/registry.npmjs.org/ionic/.cache.json
55 silly addNameRange number 2 { name: 'ionic', range: '*', hasData: true }
56 silly addNameRange versions [ 'ionic',
56 silly addNameRange   [ '0.9.6',
56 silly addNameRange     '0.9.8',
56 silly addNameRange     '0.9.9',
56 silly addNameRange     '0.9.10',
56 silly addNameRange     '0.9.11',
56 silly addNameRange     '0.9.12',
56 silly addNameRange     '0.9.13',
56 silly addNameRange     '0.9.14',
56 silly addNameRange     '0.9.15',
56 silly addNameRange     '0.9.16',
56 silly addNameRange     '1.0.0-beta.1',
56 silly addNameRange     '1.0.0-beta',
56 silly addNameRange     '1.0.1-beta',
56 silly addNameRange     '1.0.3-beta',
56 silly addNameRange     '1.0.4',
56 silly addNameRange     '1.0.5',
56 silly addNameRange     '1.0.6',
56 silly addNameRange     '1.0.7',
56 silly addNameRange     '1.0.8',
56 silly addNameRange     '1.0.9',
56 silly addNameRange     '1.0.10',
56 silly addNameRange     '1.0.11',
56 silly addNameRange     '1.0.12',
56 silly addNameRange     '1.0.13',
56 silly addNameRange     '1.0.14',
56 silly addNameRange     '1.0.15',
56 silly addNameRange     '1.0.16',
56 silly addNameRange     '1.0.17',
56 silly addNameRange     '1.1.0-beta1',
56 silly addNameRange     '1.1.0-beta2',
56 silly addNameRange     '1.1.0-beta3',
56 silly addNameRange     '1.1.0-beta4',
56 silly addNameRange     '1.1.0-beta5',
56 silly addNameRange     '1.1.0-beta6',
56 silly addNameRange     '1.1.0',
56 silly addNameRange     '1.1.1-beta1',
56 silly addNameRange     '1.1.1-beta2',
56 silly addNameRange     '1.1.1-beta3',
56 silly addNameRange     '1.1.1',
56 silly addNameRange     '1.1.3',
56 silly addNameRange     '1.1.4',
56 silly addNameRange     '1.1.5-beta1',
56 silly addNameRange     '1.1.5-beta2',
56 silly addNameRange     '1.1.5-beta3',
56 silly addNameRange     '1.1.5-beta4',
56 silly addNameRange     '1.1.5-beta5',
56 silly addNameRange     '1.1.5',
56 silly addNameRange     '1.1.6',
56 silly addNameRange     '1.1.7-beta1',
56 silly addNameRange     '1.1.7',
56 silly addNameRange     '1.1.8-beta1',
56 silly addNameRange     '1.1.8-beta2',
56 silly addNameRange     '1.1.8-beta3',
56 silly addNameRange     '1.1.8-beta4',
56 silly addNameRange     '1.1.8-beta5',
56 silly addNameRange     '1.1.8',
56 silly addNameRange     '1.1.9-beta1',
56 silly addNameRange     '1.1.9',
56 silly addNameRange     '1.1.10',
56 silly addNameRange     '1.1.11-beta1',
56 silly addNameRange     '1.1.11-beta2',
56 silly addNameRange     '1.1.11',
56 silly addNameRange     '1.1.12-beta1',
56 silly addNameRange     '1.1.12-beta2',
56 silly addNameRange     '1.1.12-beta3',
56 silly addNameRange     '1.1.12',
56 silly addNameRange     '1.1.13',
56 silly addNameRange     '1.1.14-beta1',
56 silly addNameRange     '1.1.14-beta2',
56 silly addNameRange     '1.1.14-beta3',
56 silly addNameRange     '1.2.0-beta1',
56 silly addNameRange     '1.2.0',
56 silly addNameRange     '1.2.1-beta1',
56 silly addNameRange     '1.2.1-beta2',
56 silly addNameRange     '1.2.1-beta3',
56 silly addNameRange     '1.2.1-beta4',
56 silly addNameRange     '1.2.1',
56 silly addNameRange     '1.2.2',
56 silly addNameRange     '1.2.3-beta1',
56 silly addNameRange     '1.2.3-beta2',
56 silly addNameRange     '1.2.3-beta3',
56 silly addNameRange     '1.2.3',
56 silly addNameRange     '1.2.4-beta1',
56 silly addNameRange     '1.2.4-beta2',
56 silly addNameRange     '1.2.4-beta3',
56 silly addNameRange     '1.2.4',
56 silly addNameRange     '1.2.5-beta1',
56 silly addNameRange     '1.2.5-beta2',
56 silly addNameRange     '1.2.5-beta3',
56 silly addNameRange     '1.2.5',
56 silly addNameRange     '1.2.6-beta1',
56 silly addNameRange     '1.2.6-beta2',
56 silly addNameRange     '1.2.6-beta3',
56 silly addNameRange     '1.2.6',
56 silly addNameRange     '1.2.7',
56 silly addNameRange     '1.2.8-beta1',
56 silly addNameRange     '1.2.8-beta2',
56 silly addNameRange     '1.2.8',
56 silly addNameRange     '1.2.9',
56 silly addNameRange     '1.2.10',
56 silly addNameRange     '1.2.11',
56 silly addNameRange     '1.2.12',
56 silly addNameRange     '1.2.13',
56 silly addNameRange     '1.2.14-beta1',
56 silly addNameRange     '1.2.14-beta2',
56 silly addNameRange     '1.2.14-beta3',
56 silly addNameRange     '1.2.14-beta4',
56 silly addNameRange     '1.2.14-beta5',
56 silly addNameRange     '1.2.14-beta6',
56 silly addNameRange     '1.2.14',
56 silly addNameRange     '1.3.0-beta1',
56 silly addNameRange     '1.3.0',
56 silly addNameRange     '1.3.1',
56 silly addNameRange     '1.3.2',
56 silly addNameRange     '1.3.3',
56 silly addNameRange     '1.3.4',
56 silly addNameRange     '1.3.5',
56 silly addNameRange     '1.3.6',
56 silly addNameRange     '1.3.7',
56 silly addNameRange     '1.3.8',
56 silly addNameRange     '1.3.9',
56 silly addNameRange     '1.3.10',
56 silly addNameRange     '1.4.0-alpha.1',
56 silly addNameRange     '1.3.11',
56 silly addNameRange     '1.3.1-1.alpha.0',
56 silly addNameRange     '1.4.0-alpha.2',
56 silly addNameRange     '1.3.12',
56 silly addNameRange     '1.3.12-beta.1',
56 silly addNameRange     '1.3.12-beta.2',
56 silly addNameRange     '1.3.13-beta.0',
56 silly addNameRange     '1.3.1-3.beta.1',
56 silly addNameRange     '1.3.1-3.beta.2',
56 silly addNameRange     '1.3.13',
56 silly addNameRange     '1.3.1-3.beta.4',
56 silly addNameRange     '1.3.14-beta',
56 silly addNameRange     '1.3.14-beta.1',
56 silly addNameRange     '1.4.0-alpha.3',
56 silly addNameRange     '1.3.14',
56 silly addNameRange     '1.4.0-alpha.4',
56 silly addNameRange     '1.4.0-alpha.5',
56 silly addNameRange     '1.3.15-beta.0',
56 silly addNameRange     '1.3.15-beta.1',
56 silly addNameRange     '1.3.15-beta.2',
56 silly addNameRange     '1.3.15-beta.3',
56 silly addNameRange     '1.3.15-beta.4',
56 silly addNameRange     '1.3.15',
56 silly addNameRange     '1.3.16',
56 silly addNameRange     '1.4.0-alpha.6',
56 silly addNameRange     '1.3.17-beta.0',
56 silly addNameRange     '1.3.17-beta.1',
56 silly addNameRange     '1.3.17-beta.2',
56 silly addNameRange     '1.3.17-beta.3',
56 silly addNameRange     '1.3.1-7.beta.4',
56 silly addNameRange     '1.3.17',
56 silly addNameRange     '1.3.18-beta.0',
56 silly addNameRange     '1.3.18-beta.1',
56 silly addNameRange     '1.3.18-beta.2',
56 silly addNameRange     '1.3.18-beta.3',
56 silly addNameRange     '1.3.18',
56 silly addNameRange     '1.3.19-beta.0',
56 silly addNameRange     '1.3.19-beta.1',
56 silly addNameRange     '1.3.19-beta.2',
56 silly addNameRange     '1.3.19-beta.3',
56 silly addNameRange     '1.3.19-beta.4',
56 silly addNameRange     '1.3.19',
56 silly addNameRange     '1.3.20',
56 silly addNameRange     '1.4.1-beta.0',
56 silly addNameRange     '1.4.0-beta.1',
56 silly addNameRange     '1.4.0-beta.2',
56 silly addNameRange     '1.4.0-beta.3',
56 silly addNameRange     '1.4.0-beta.5',
56 silly addNameRange     '1.4.0-beta.6',
56 silly addNameRange     '1.4.0-beta.7',
56 silly addNameRange     '1.3.21-beta.0',
56 silly addNameRange     '1.3.21-beta.1',
56 silly addNameRange     '1.3.21',
56 silly addNameRange     '1.3.22',
56 silly addNameRange     '1.4.0-beta.8',
56 silly addNameRange     '1.4.0-beta.9',
56 silly addNameRange     '1.4.0-beta.10',
56 silly addNameRange     '1.4.0-beta.11',
56 silly addNameRange     '1.4.0-beta.12',
56 silly addNameRange     '1.4.0-beta.13',
56 silly addNameRange     '1.4.0-beta.14',
56 silly addNameRange     '1.4.0-beta.15',
56 silly addNameRange     '1.4.0-beta.16',
56 silly addNameRange     '1.4.0-beta.17',
56 silly addNameRange     '1.4.0-beta.18',
56 silly addNameRange     '1.4.0',
56 silly addNameRange     '1.4.1',
56 silly addNameRange     '1.4.2',
56 silly addNameRange     '1.4.3',
56 silly addNameRange     '1.4.4-beta.0',
56 silly addNameRange     '1.4.4-beta.2',
56 silly addNameRange     '1.4.4',
56 silly addNameRange     '1.4.5-beta.0',
56 silly addNameRange     '1.4.5-beta.1',
56 silly addNameRange     '1.4.5-beta.2',
56 silly addNameRange     '1.4.5-beta.3',
56 silly addNameRange     '1.4.5',
56 silly addNameRange     '1.4.6-beta.0' ] ]
57 verbose addNamed ionic@1.4.5
58 silly addNamed semver.valid 1.4.5
59 silly addNamed semver.validRange 1.4.5
60 silly cache afterAdd ionic@1.4.5
61 verbose afterAdd /Users/csutaria/.npm/ionic/1.4.5/package/package.json not in flight; writing
62 verbose afterAdd /Users/csutaria/.npm/ionic/1.4.5/package/package.json written
63 silly install resolved [ { name: 'cordova',
63 silly install resolved     version: '5.0.0',
63 silly install resolved     preferGlobal: 'true',
63 silly install resolved     description: 'Cordova command line interface tool',
63 silly install resolved     main: 'cordova',
63 silly install resolved     engines: { node: '>=0.9.9' },
63 silly install resolved     engineStrict: true,
63 silly install resolved     bin: { cordova: './bin/cordova' },
63 silly install resolved     scripts:
63 silly install resolved      { test: 'node node_modules/jasmine-node/bin/jasmine-node --captureExceptions --color spec',
63 silly install resolved        cover: 'node node_modules/istanbul/lib/cli.js cover --root src --print detail node_modules/jasmine-node/bin/jasmine-node -- spec' },
63 silly install resolved     repository:
63 silly install resolved      { type: 'git',
63 silly install resolved        url: 'https://git-wip-us.apache.org/repos/asf/cordova-cli.git' },
63 silly install resolved     bugs:
63 silly install resolved      { url: 'https://issues.apache.org/jira/browse/CB',
63 silly install resolved        email: 'dev@cordova.apache.org' },
63 silly install resolved     keywords: [ 'cordova', 'client', 'cli' ],
63 silly install resolved     dependencies:
63 silly install resolved      { 'cordova-lib': '5.0.0',
63 silly install resolved        q: '1.0.1',
63 silly install resolved        nopt: '3.0.1',
63 silly install resolved        underscore: '1.7.0' },
63 silly install resolved     devDependencies:
63 silly install resolved      { istanbul: '^0.3.4',
63 silly install resolved        grunt: '0.4.5',
63 silly install resolved        'grunt-retire': '0.3.7',
63 silly install resolved        'jasmine-node': '1.14.5' },
63 silly install resolved     author: { name: 'Anis Kadri' },
63 silly install resolved     contributors:
63 silly install resolved      [ [Object],
63 silly install resolved        [Object] ],
63 silly install resolved     license: 'Apache version 2.0',
63 silly install resolved     _id: 'cordova@5.0.0',
63 silly install resolved     _shasum: '696907aff7c889beea4422b6c80e57558a905c05',
63 silly install resolved     _resolved: 'https://registry.npmjs.org/cordova/-/cordova-5.0.0.tgz',
63 silly install resolved     _from: 'cordova@*',
63 silly install resolved     _npmVersion: '2.7.0',
63 silly install resolved     _nodeVersion: '0.10.36',
63 silly install resolved     _npmUser: { name: 'stevegill', email: 'stevengill97@gmail.com' },
63 silly install resolved     maintainers:
63 silly install resolved      [ [Object],
63 silly install resolved        [Object] ],
63 silly install resolved     dist:
63 silly install resolved      { shasum: '696907aff7c889beea4422b6c80e57558a905c05',
63 silly install resolved        tarball: 'http://registry.npmjs.org/cordova/-/cordova-5.0.0.tgz' },
63 silly install resolved     directories: {},
63 silly install resolved     readme: 'ERROR: No README data found!' },
63 silly install resolved   { name: 'ionic',
63 silly install resolved     version: '1.4.5',
63 silly install resolved     preferGlobal: true,
63 silly install resolved     description: 'A tool for creating and developing Ionic Framework mobile apps.',
63 silly install resolved     homepage: 'http://ionicframework.com/',
63 silly install resolved     bin: { ionic: 'bin/ionic' },
63 silly install resolved     scripts:
63 silly install resolved      { bump: 'node lib/tasks/bumpversion',
63 silly install resolved        'beta-bump': 'node lib/tasks/bumpversion --level pre --identifier beta',
63 silly install resolved        'publish-release': 'node lib/tasks/bumpversion --npmPublish',
63 silly install resolved        'publish-tag': 'node lib/tasks/bumpversion --level beta --npmPublishTag',
63 silly install resolved        'full-release': 'node lib/tasks/bumpversion --npmInstall --git --npmPublish',
63 silly install resolved        test: 'npm run jasmine',
63 silly install resolved        e2e: 'jasmine-node --captureExceptions ./e2e',
63 silly install resolved        jasmine: 'jasmine-node --captureExceptions  ./spec' },
63 silly install resolved     keywords:
63 silly install resolved      [ 'ionic',
63 silly install resolved        'ionic framework',
63 silly install resolved        'ionicframework',
63 silly install resolved        'mobile',
63 silly install resolved        'app',
63 silly install resolved        'hybrid',
63 silly install resolved        'cordova',
63 silly install resolved        'phonegap' ],
63 silly install resolved     repository:
63 silly install resolved      { type: 'git',
63 silly install resolved        url: 'https://github.com/driftyco/ionic-cli.git' },
63 silly install resolved     contributors: [ [Object], [Object], [Object], [Object] ],
63 silly install resolved     license: 'MIT',
63 silly install resolved     dependencies:
63 silly install resolved      { archiver: '0.5.1',
63 silly install resolved        async: '^0.9.0',
63 silly install resolved        cheerio: '^0.19.0',
63 silly install resolved        'cli-table': '^0.3.1',
63 silly install resolved        colors: '0.6.2',
63 silly install resolved        connect: '3.1.1',
63 silly install resolved        'connect-livereload': '0.5.2',
63 silly install resolved        crc: '3.2.1',
63 silly install resolved        'cross-spawn': '0.2.3',
63 silly install resolved        'event-stream': '3.0.x',
63 silly install resolved        finalhandler: '0.2.0',
63 silly install resolved        'form-data': '0.1.4',
63 silly install resolved        gulp: '3.8.8',
63 silly install resolved        'ionic-app-lib': '0.0.22',
63 silly install resolved        ncp: '0.4.2',
63 silly install resolved        npm: '2.1.3',
63 silly install resolved        'opbeat-ionic': '^1.1.3',
63 silly install resolved        open: '0.0.5',
63 silly install resolved        optimist: '0.6.0',
63 silly install resolved        progress: '1.1.7',
63 silly install resolved        prompt: '0.2.12',
63 silly install resolved        'proxy-middleware': '^0.7.0',
63 silly install resolved        q: '1.0.1',
63 silly install resolved        request: '2.51.0',
63 silly install resolved        semver: '^4.2.0',
63 silly install resolved        'serve-static': '1.7.1',
63 silly install resolved        shelljs: '0.2.6',
63 silly install resolved        'tiny-lr-fork': '0.0.5',
63 silly install resolved        underscore: '~1.7.0',
63 silly install resolved        unzip: '0.1.9',
63 silly install resolved        'vinyl-fs': '0.3.7',
63 silly install resolved        xml2js: '0.4.4' },
63 silly install resolved     devDependencies: { 'jasmine-node': '^1.14.5' },
63 silly install resolved     gitHead: '4da736396f7c1a23b15716c62839ba5f411b4d8e',
63 silly install resolved     bugs: { url: 'https://github.com/driftyco/ionic-cli/issues' },
63 silly install resolved     _id: 'ionic@1.4.5',
63 silly install resolved     _shasum: 'def0d7eb8b67e1f8e97b8657ce5e2cae4786a6ed',
63 silly install resolved     _from: 'ionic@*',
63 silly install resolved     _npmVersion: '2.5.1',
63 silly install resolved     _nodeVersion: '0.10.33',
63 silly install resolved     _npmUser: { name: 'jbavari', email: 'jbavari@gmail.com' },
63 silly install resolved     dist:
63 silly install resolved      { shasum: 'def0d7eb8b67e1f8e97b8657ce5e2cae4786a6ed',
63 silly install resolved        tarball: 'http://registry.npmjs.org/ionic/-/ionic-1.4.5.tgz' },
63 silly install resolved     maintainers: [ [Object], [Object], [Object] ],
63 silly install resolved     directories: {},
63 silly install resolved     _resolved: 'https://registry.npmjs.org/ionic/-/ionic-1.4.5.tgz',
63 silly install resolved     readme: 'ERROR: No README data found!' } ]
64 info install cordova@5.0.0 into /usr/local/lib
65 info install ionic@1.4.5 into /usr/local/lib
66 info installOne cordova@5.0.0
67 verbose installOne of cordova to /usr/local/lib not in flight; installing
68 info installOne ionic@1.4.5
69 verbose installOne of ionic to /usr/local/lib not in flight; installing
70 verbose lock using /Users/csutaria/.npm/_locks/ionic-61c0cd50dc7a1457.lock for /usr/local/lib/node_modules/ionic
71 verbose lock using /Users/csutaria/.npm/_locks/cordova-fa12e2e096426a32.lock for /usr/local/lib/node_modules/cordova
72 silly install write writing ionic 1.4.5 to /usr/local/lib/node_modules/ionic
73 silly cache addNamed cb ionic@1.4.5
74 verbose unbuild lib/node_modules/ionic
75 silly install write writing cordova 5.0.0 to /usr/local/lib/node_modules/cordova
76 silly cache addNamed cb cordova@5.0.0
77 verbose unbuild lib/node_modules/cordova
78 silly gentlyRm /usr/local/lib/node_modules/ionic is being purged from base /usr/local
79 verbose gentlyRm don't care about contents; nuking /usr/local/lib/node_modules/ionic
80 verbose tar unpack /Users/csutaria/.npm/ionic/1.4.5/package.tgz
81 verbose tar unpacking to /usr/local/lib/node_modules/ionic
82 silly gentlyRm /usr/local/lib/node_modules/ionic is being purged
83 verbose gentlyRm don't care about contents; nuking /usr/local/lib/node_modules/ionic
84 silly gunzTarPerm modes [ '755', '644' ]
85 info preuninstall cordova@5.0.0
86 info uninstall cordova@5.0.0
87 verbose unbuild rmStuff cordova@5.0.0 from /usr/local/lib/node_modules
88 silly gentlyRm /usr/local/bin/cordova is being gently removed
89 silly gentlyRm verifying /usr/local is an npm working directory
90 error tar.unpack untar error /Users/csutaria/.npm/ionic/1.4.5/package.tgz
91 silly gentlyRm containing path /usr/local is under npm's control, in /usr/local
92 silly gentlyRm deletion target /usr/local/bin/cordova is under /usr/local
93 verbose gentlyRm vacuuming from /usr/local/bin/cordova up to /usr/local
94 verbose unlock done using /Users/csutaria/.npm/_locks/ionic-61c0cd50dc7a1457.lock for /usr/local/lib/node_modules/ionic
95 info postuninstall cordova@5.0.0
96 silly gentlyRm /usr/local/lib/node_modules/cordova is being purged from base /usr/local
97 verbose gentlyRm don't care about contents; nuking /usr/local/lib/node_modules/cordova
98 silly vacuum-fs purging /usr/local/lib/node_modules/cordova
99 verbose unlock done using /Users/csutaria/.npm/_locks/cordova-fa12e2e096426a32.lock for /usr/local/lib/node_modules/cordova
100 verbose fstream_path /usr/local/lib/node_modules/ionic
101 verbose fstream_type Directory
102 verbose fstream_class DirWriter
103 verbose stack Error: EACCES, mkdir '/usr/local/lib/node_modules/ionic'
103 verbose stack     at Error (native)
104 verbose fstream_stack /usr/local/lib/node_modules/npm/node_modules/fstream/lib/dir-writer.js:36:23
104 verbose fstream_stack /usr/local/lib/node_modules/npm/node_modules/mkdirp/index.js:46:53
104 verbose fstream_stack FSReqWrap.oncomplete (fs.js:95:15)
105 verbose cwd /Users/csutaria
106 error Darwin 14.3.0
107 error argv "node" "/usr/local/bin/npm" "install" "-g" "cordova" "ionic"
108 error node v0.12.2
109 error npm  v2.7.4
110 error path /usr/local/lib/node_modules/ionic
111 error code EACCES
112 error errno -13
113 error Error: EACCES, mkdir '/usr/local/lib/node_modules/ionic'
113 error     at Error (native)
113 error  { [Error: EACCES, mkdir '/usr/local/lib/node_modules/ionic']
113 error   errno: -13,
113 error   code: 'EACCES',
113 error   path: '/usr/local/lib/node_modules/ionic',
113 error   fstream_type: 'Directory',
113 error   fstream_path: '/usr/local/lib/node_modules/ionic',
113 error   fstream_class: 'DirWriter',
113 error   fstream_stack:
113 error    [ '/usr/local/lib/node_modules/npm/node_modules/fstream/lib/dir-writer.js:36:23',
113 error      '/usr/local/lib/node_modules/npm/node_modules/mkdirp/index.js:46:53',
113 error      'FSReqWrap.oncomplete (fs.js:95:15)' ] }
114 error Please try running this command again as root/Administrator.
115 verbose exit [ -13, true ]
116 verbose unbuild lib/node_modules/ionic
117 silly gentlyRm /usr/local/lib/node_modules/ionic is being purged from base /usr/local
118 verbose gentlyRm don't care about contents; nuking /usr/local/lib/node_modules/ionic
119 verbose unbuild lib/node_modules/cordova
120 info preuninstall cordova@5.0.0
121 info uninstall cordova@5.0.0
122 verbose unbuild rmStuff cordova@5.0.0 from /usr/local/lib/node_modules
123 silly gentlyRm /usr/local/bin/cordova is being gently removed
124 silly gentlyRm verifying /usr/local is an npm working directory
125 silly gentlyRm containing path /usr/local is under npm's control, in /usr/local
126 silly gentlyRm deletion target /usr/local/bin/cordova is under /usr/local
127 verbose gentlyRm vacuuming from /usr/local/bin/cordova up to /usr/local
128 info postuninstall cordova@5.0.0
129 silly gentlyRm /usr/local/lib/node_modules/cordova is being purged from base /usr/local
130 verbose gentlyRm don't care about contents; nuking /usr/local/lib/node_modules/cordova
131 silly vacuum-fs purging /usr/local/lib/node_modules/cordova
132 error error rolling back Error: EACCES, rmdir '/usr/local/lib/node_modules/cordova'
132 error error rolling back     at Error (native)
132 error error rolling back  { [Error: EACCES, rmdir '/usr/local/lib/node_modules/cordova']
132 error error rolling back   errno: -13,
132 error error rolling back   code: 'EACCES',
132 error error rolling back   path: '/usr/local/lib/node_modules/cordova' }

#5

@csutaria Have you resolved this issue? I am have the same problem.

Thanks,


#6

i also have the same problem
have u resolved this issue?


#7

Unfortunately no solution yet. I got it working using sudo once, but then after a few weeks, there was an update I needed to install. When I tried that, everything got messed up again… Don’t know how to fix it.

Below link is a solution someone suggested to my post on stackoverflow. Didn’t work for me this time, but maybe it would help one of you.


#8

I’m running OS X Yosemite, NodeJS ($node --version) v0.12.5 and npm ($ npm --version) 2.11.2

Did you install Node via Homebrew (http://brew.sh/) or nvm ( https://github.com/creationix/nvm)?


#9

thank u i also have the same problem when i try to update the ionic-cli


#10

I believe the issue may have been caused by a recent migration to OS X Yosemite.

What fixed the problem for me was to uninstall then reinstall node via brew:

npm cache clean
brew uninstall --force node
rm -r /usr/local/lib/node_modules
brew install node
’which node’ returns /usr/local/bin/node

And, to set NODE_PATH in my .bash_profile:

export NODE_PATH=/usr/local/lib/node_modules
Note: npm works without sudo