Getting started with AngularJS on ubuntu vagrant virtualbox, npm start fails - angularjs

I am following the tutorial on
https://docs.angularjs.org/tutorial
to get started with AngularJS on my ubuntu vagrant virtualbox.
I believe that I have followed all of the steps, but I can't get npm start to work.
I get the following response when running npm start:
(test5)vagrant#vagrant-ubuntu-trusty-32:/vagrant/angular-phonecat$ npm start
> angular-phonecat#0.0.0 prestart /vagrant/angular-phonecat
> npm install
...truncated
npm ERR! error rolling back Error: UNKNOWN, unlink '/vagrant/angular-phonecat/node_modules/karma/node_modules/connect/History.md'
npm ERR! error rolling back karma#0.12.37 { [Error: UNKNOWN, unlink '/vagrant/angular-phonecat/node_modules/karma/node_modules/connect/History.md']
npm ERR! error rolling back errno: -1,
npm ERR! error rolling back code: 'UNKNOWN',
npm ERR! error rolling back path: '/vagrant/angular-phonecat/node_modules/karma/node_modules/connect/History.md' }
npm ERR! Error: ENOENT, open '/vagrant/angular-phonecat/node_modules/karma/node_modules/lodash/index.js'
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR! path /vagrant/angular-phonecat/node_modules/karma/node_modules/lodash/index.js
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! Error: ENOENT, chmod '/vagrant/angular-phonecat/node_modules/karma/node_modules/colors/lib/custom/trap.js'
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR! path /vagrant/angular-phonecat/node_modules/karma/node_modules/colors/lib/custom/trap.js
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/karma/node_modules/colors/lib/custom/trap.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! fstream_finish_call chmod
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack /usr/lib/nodejs/fstream/lib/writer.js:305:19
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm http GET https://registry.npmjs.org/amdefine
npm http 304 https://registry.npmjs.org/amdefine
npm http GET https://registry.npmjs.org/lru-cache
npm http 304 https://registry.npmjs.org/lru-cache
npm http GET https://registry.npmjs.org/lru-cache/-/lru-cache-2.2.4.tgz
npm http 200 https://registry.npmjs.org/lru-cache/-/lru-cache-2.2.4.tgz
npm http GET https://registry.npmjs.org/ent
npm http GET https://registry.npmjs.org/optimist
npm http GET https://registry.npmjs.org/mime/-/mime-1.2.11.tgz
npm http 304 https://registry.npmjs.org/optimist
npm http GET https://registry.npmjs.org/optimist/-/optimist-0.3.7.tgz
npm http 200 https://registry.npmjs.org/mime/-/mime-1.2.11.tgz
npm http 200 https://registry.npmjs.org/ent
npm http GET https://registry.npmjs.org/ent/-/ent-0.0.7.tgz
npm http 200 https://registry.npmjs.org/optimist/-/optimist-0.3.7.tgz
npm http GET https://registry.npmjs.org/pkginfo
npm http GET https://registry.npmjs.org/utile
npm http GET https://registry.npmjs.org/colors
npm http 200 https://registry.npmjs.org/utile
npm http GET https://registry.npmjs.org/utile/-/utile-0.2.1.tgz
npm http 200 https://registry.npmjs.org/utile/-/utile-0.2.1.tgz
npm http 200 https://registry.npmjs.org/pkginfo
npm http GET https://registry.npmjs.org/pkginfo/-/pkginfo-0.3.0.tgz
npm http 200 https://registry.npmjs.org/pkginfo/-/pkginfo-0.3.0.tgz
npm http GET https://registry.npmjs.org/request
npm http GET https://registry.npmjs.org/selenium-webdriver/2.47.0
npm http GET https://registry.npmjs.org/jasminewd/1.1.0
npm http GET https://registry.npmjs.org/minijasminenode/1.1.1
npm http GET https://registry.npmjs.org/jasminewd2/0.0.6
npm http GET https://registry.npmjs.org/jasmine/2.3.2
npm http GET https://registry.npmjs.org/saucelabs
npm http GET https://registry.npmjs.org/glob
npm http GET https://registry.npmjs.org/adm-zip/0.4.4
npm http GET https://registry.npmjs.org/q/1.0.0
npm http GET https://registry.npmjs.org/lodash
npm http GET https://registry.npmjs.org/source-map-support
npm http GET https://registry.npmjs.org/html-entities
npm http GET https://registry.npmjs.org/accessibility-developer-tools
npm http 304 https://registry.npmjs.org/request
npm http 304 https://registry.npmjs.org/selenium-webdriver/2.47.0
npm http 304 https://registry.npmjs.org/minijasminenode/1.1.1
npm http 304 https://registry.npmjs.org/jasminewd/1.1.0
npm http 304 https://registry.npmjs.org/jasminewd2/0.0.6
npm http 304 https://registry.npmjs.org/jasmine/2.3.2
npm http 304 https://registry.npmjs.org/glob
npm http 304 https://registry.npmjs.org/adm-zip/0.4.4
npm http 304 https://registry.npmjs.org/q/1.0.0
npm http 304 https://registry.npmjs.org/lodash
npm http 304 https://registry.npmjs.org/source-map-support
npm http 304 https://registry.npmjs.org/html-entities
npm http 304 https://registry.npmjs.org/saucelabs
npm http 304 https://registry.npmjs.org/accessibility-developer-tools
npm WARN engine selenium-webdriver#2.47.0: wanted: {"node":">= 0.12.x"} (current: {"node":"0.10.25","npm":"1.3.10"})
npm http GET https://registry.npmjs.org/exit
npm http GET https://registry.npmjs.org/jasmine-core
npm http GET https://registry.npmjs.org/https-proxy-agent
npm http 304 https://registry.npmjs.org/exit
npm http 200 https://registry.npmjs.org/ent/-/ent-0.0.7.tgz
npm http 304 https://registry.npmjs.org/jasmine-core
npm http 304 https://registry.npmjs.org/https-proxy-agent
npm http 304 https://registry.npmjs.org/colors
npm http GET https://registry.npmjs.org/inherits
npm http GET https://registry.npmjs.org/minimatch
npm http GET https://registry.npmjs.org/wordwrap
npm http GET https://registry.npmjs.org/minimist
npm http 304 https://registry.npmjs.org/minimatch
npm http 304 https://registry.npmjs.org/inherits
npm http 304 https://registry.npmjs.org/wordwrap
npm http 304 https://registry.npmjs.org/minimist
npm http GET https://registry.npmjs.org/agent-base
npm http GET https://registry.npmjs.org/debug
npm http GET https://registry.npmjs.org/extend
npm http 304 https://registry.npmjs.org/extend
npm http 304 https://registry.npmjs.org/debug
npm http 304 https://registry.npmjs.org/agent-base
npm ERR! EEXIST, mkdir '/vagrant/angular-phonecat/node_modules/protractor/node_modules/lodash'
File exists: /vagrant/angular-phonecat/node_modules/protractor/node_modules/lodash
Move it away, and try again.
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR! path /vagrant/angular-phonecat/node_modules/protractor/node_modules/lodash
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/protractor/node_modules/lodash/LICENSE.txt
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code EEXIST
npm ERR! errno 47
npm ERR! fstream_stack /usr/lib/nodejs/fstream/lib/writer.js:171:23
npm ERR! fstream_stack /usr/lib/nodejs/mkdirp/index.js:37:53
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm http GET https://registry.npmjs.org/source-map/0.1.32
npm ERR! error rolling back Error: UNKNOWN, unlink '/vagrant/angular-phonecat/node_modules/protractor/node_modules/adm-zip/methods/deflater.js'
npm ERR! error rolling back protractor#2.5.1 { [Error: UNKNOWN, unlink '/vagrant/angular-phonecat/node_modules/protractor/node_modules/adm-zip/methods/deflater.js']
npm ERR! error rolling back errno: -1,
npm ERR! error rolling back code: 'UNKNOWN',
npm ERR! error rolling back path: '/vagrant/angular-phonecat/node_modules/protractor/node_modules/adm-zip/methods/deflater.js' }
npm ERR! Error: ENOENT, lstat '/vagrant/angular-phonecat/node_modules/protractor/node_modules/request/lib/redirect.js'
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR! path /vagrant/angular-phonecat/node_modules/protractor/node_modules/request/lib/redirect.js
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/protractor/node_modules/request/lib/redirect.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack /usr/lib/nodejs/fstream/lib/writer.js:284:26
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm http 304 https://registry.npmjs.org/source-map/0.1.32
npm ERR! Error: ENOENT, open '/vagrant/angular-phonecat/node_modules/protractor/node_modules/accessibility-developer-tools/src/audits/FocusableElementNotVisibleAndNotAriaHidden.js'
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR! path /vagrant/angular-phonecat/node_modules/protractor/node_modules/accessibility-developer-tools/src/audits/FocusableElementNotVisibleAndNotAriaHidden.js
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! Error: ENOENT, chmod '/vagrant/angular-phonecat/node_modules/protractor/node_modules/optimist/node_modules/minimist/test/bool.js'
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR! path /vagrant/angular-phonecat/node_modules/protractor/node_modules/optimist/node_modules/minimist/test/bool.js
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/protractor/node_modules/optimist/node_modules/minimist/test/bool.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! fstream_finish_call chmod
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack /usr/lib/nodejs/fstream/lib/writer.js:305:19
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! Error: ENOENT, utime '/vagrant/angular-phonecat/node_modules/protractor/node_modules/optimist/node_modules/wordwrap/test/wrap.js'
npm ERR! If you need help, you may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-#googlegroups.com>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR! path /vagrant/angular-phonecat/node_modules/protractor/node_modules/optimist/node_modules/wordwrap/test/wrap.js
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/protractor/node_modules/optimist/node_modules/wordwrap/test/wrap.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! fstream_finish_call utimes
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack /usr/lib/nodejs/fstream/lib/writer.js:305:19
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! EEXIST, mkdir '/vagrant/angular-phonecat/node_modules/protractor/node_modules/jasmine/node_modules/jasmine-core/lib/jasmine-core'
File exists: /vagrant/angular-phonecat/node_modules/protractor/node_modules/jasmine/node_modules/jasmine-core/lib/jasmine-core
Move it away, and try again.
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.25
npm ERR! npm -v 1.3.10
npm ERR! path /vagrant/angular-phonecat/node_modules/protractor/node_modules/jasmine/node_modules/jasmine-core/lib/jasmine-core
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/protractor/node_modules/jasmine/node_modules/jasmine-core/lib/jasmine-core/jasmine.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code EEXIST
npm ERR! errno 47
npm ERR! fstream_stack /usr/lib/nodejs/fstream/lib/writer.js:171:23
npm ERR! fstream_stack /usr/lib/nodejs/mkdirp/index.js:37:53
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm http GET https://registry.npmjs.org/i
npm http GET https://registry.npmjs.org/ncp
npm http GET https://registry.npmjs.org/async
npm http GET https://registry.npmjs.org/deep-equal
npm http GET https://registry.npmjs.org/mkdirp
npm http 200 https://registry.npmjs.org/i
npm http 200 https://registry.npmjs.org/deep-equal
npm http 304 https://registry.npmjs.org/mkdirp
npm http 200 https://registry.npmjs.org/ncp
npm http 200 https://registry.npmjs.org/async
npm http GET https://registry.npmjs.org/i/-/i-0.3.3.tgz
npm http GET https://registry.npmjs.org/deep-equal/-/deep-equal-1.0.1.tgz
npm http GET https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz
npm http GET https://registry.npmjs.org/ncp/-/ncp-0.4.2.tgz
npm http GET https://registry.npmjs.org/async/-/async-0.2.10.tgz
npm http GET https://registry.npmjs.org/semver
npm http 200 https://registry.npmjs.org/i/-/i-0.3.3.tgz
npm http GET https://registry.npmjs.org/ms/0.7.1
npm http 200 https://registry.npmjs.org/deep-equal/-/deep-equal-1.0.1.tgz
npm http 200 https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz
npm http 200 https://registry.npmjs.org/ncp/-/ncp-0.4.2.tgz
npm http 304 https://registry.npmjs.org/semver
npm http 200 https://registry.npmjs.org/async/-/async-0.2.10.tgz
npm http 304 https://registry.npmjs.org/ms/0.7.1
npm http GET https://registry.npmjs.org/amdefine
npm http 304 https://registry.npmjs.org/amdefine
npm http GET https://registry.npmjs.org/minimist/0.0.8
npm http 200 https://registry.npmjs.org/minimist/0.0.8
npm http GET https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz
npm http 200 https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz
npm ERR! error rolling back Error: ENOTEMPTY, rmdir '/vagrant/angular-phonecat/node_modules/http-server/node_modules/ecstatic/node_modules/optimist/node_modules/wordwrap/example'
npm ERR! error rolling back ecstatic#0.4.13 { [Error: ENOTEMPTY, rmdir '/vagrant/angular-phonecat/node_modules/http-server/node_modules/ecstatic/node_modules/optimist/node_modules/wordwrap/example']
npm ERR! error rolling back errno: 53,
npm ERR! error rolling back code: 'ENOTEMPTY',
npm ERR! error rolling back path: '/vagrant/angular-phonecat/node_modules/http-server/node_modules/ecstatic/node_modules/optimist/node_modules/wordwrap/example' }
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /vagrant/angular-phonecat/npm-debug.log
npm ERR! not ok code 0
npm ERR! weird error 255
npm WARN This failure might be due to the use of legacy binary "node"
npm WARN For further explanations, please read
/usr/share/doc/nodejs/README.Debian
npm ERR! not ok code 0
What is wrong?
I have run apt-get install nodejs-legacy npm
I have the following version:
(test5)vagrant#vagrant-ubuntu-trusty-32:/vagrant/angular-phonecat$ nodejs --version
v0.10.25
(test5)vagrant#vagrant-ubuntu-trusty-32:/vagrant/angular-phonecat$ npm --version1.3.10
The guide indicates that I should have Node.js v0.10.27+, but that seems strange to me as I have followed the guide and have ended up with v0.10.25.
If I need a newer verison of Node.js I would appreciate advice on which file I should download from here:
https://nodejs.org/download/release/v4.2.1/
and also how I should install it once I download it to my vagrant folder.
EDIT
Based on the comments Based I installed nvm (liquidweb.com/kb/…) and changed the currently used version to 0.10.27 (stackoverflow.com/questions/7718313/…). I till get errors when I execute npm start.
vagrant#vagrant-ubuntu-trusty-32:/vagrant/angular-phonecat$ npm start
> angular-phonecat#0.0.0 prestart /vagrant/angular-phonecat
> npm install
...
npm ERR! Error: UNKNOWN, symlink '../shelljs/bin/shjs'
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/npm/npm/issues>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/home/vagrant/.nvm/v0.10.27/bin/node" "/home/vagrant/.nvm/v0.10.27/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.27
npm ERR! npm -v 1.4.8
npm ERR! path ../shelljs/bin/shjs
npm ERR! code UNKNOWN
npm ERR! errno -1
...
npm ERR! EEXIST, mkdir '/vagrant/angular-phonecat/node_modules/http-server/node_modules/optimist/example'
File exists: /vagrant/angular-phonecat/node_modules/http-server/node_modules/optimist/example
Move it away, and try again.
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/home/vagrant/.nvm/v0.10.27/bin/node" "/home/vagrant/.nvm/v0.10.27/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.27
npm ERR! npm -v 1.4.8
npm ERR! path /vagrant/angular-phonecat/node_modules/http-server/node_modules/optimist/example
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/http-server/node_modules/optimist/example/default_hash.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code EEXIST
npm ERR! errno 47
npm ERR! fstream_stack /home/vagrant/.nvm/v0.10.27/lib/node_modules/npm/node_modules/fstream/lib/writer.js:171:23
npm ERR! fstream_stack /home/vagrant/.nvm/v0.10.27/lib/node_modules/npm/node_modules/mkdirp/index.js:37:53
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! error rolling back Error: ENOTEMPTY, rmdir '/vagrant/angular-phonecat/node_modules/http-server/node_modules/union/examples'
npm ERR! error rolling back http-server#0.6.1 { [Error: ENOTEMPTY, rmdir '/vagrant/angular-phonecat/node_modules/http-server/node_modules/union/examples']
npm ERR! error rolling back errno: 53,
npm ERR! error rolling back code: 'ENOTEMPTY',
npm ERR! error rolling back path: '/vagrant/angular-phonecat/node_modules/http-server/node_modules/union/examples' }
npm http GET https://registry.npmjs.org/mkdirp
npm http 304 https://registry.npmjs.org/mkdirp
npm ERR! error rolling back Error: ETXTBSY, unlink '/vagrant/angular-phonecat/node_modules/karma/node_modules/connect/History.md'
npm ERR! error rolling back karma#0.12.37 { [Error: ETXTBSY, unlink '/vagrant/angular-phonecat/node_modules/karma/node_modules/connect/History.md']
npm ERR! error rolling back errno: 62,
npm ERR! error rolling back code: 'ETXTBSY',
npm ERR! error rolling back path: '/vagrant/angular-phonecat/node_modules/karma/node_modules/connect/History.md' }
npm ERR! Error: ENOENT, lstat '/vagrant/angular-phonecat/node_modules/karma/node_modules/optimist/example/reflect.js'
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/npm/npm/issues>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/home/vagrant/.nvm/v0.10.27/bin/node" "/home/vagrant/.nvm/v0.10.27/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.27
npm ERR! npm -v 1.4.8
npm ERR! path /vagrant/angular-phonecat/node_modules/karma/node_modules/optimist/example/reflect.js
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/karma/node_modules/optimist/example/reflect.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack /home/vagrant/.nvm/v0.10.27/lib/node_modules/npm/node_modules/fstream/lib/writer.js:284:26
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! Error: ENOENT, chmod '/vagrant/angular-phonecat/node_modules/karma/node_modules/useragent/features/index.js'
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/npm/npm/issues>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/home/vagrant/.nvm/v0.10.27/bin/node" "/home/vagrant/.nvm/v0.10.27/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.27
npm ERR! npm -v 1.4.8
npm ERR! path /vagrant/angular-phonecat/node_modules/karma/node_modules/useragent/features/index.js
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/karma/node_modules/useragent/features/index.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! fstream_finish_call chmod
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack /home/vagrant/.nvm/v0.10.27/lib/node_modules/npm/node_modules/fstream/lib/writer.js:305:19
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! EEXIST, mkdir '/vagrant/angular-phonecat/node_modules/karma/node_modules/source-map/build'
File exists: /vagrant/angular-phonecat/node_modules/karma/node_modules/source-map/build
Move it away, and try again.
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/home/vagrant/.nvm/v0.10.27/bin/node" "/home/vagrant/.nvm/v0.10.27/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.27
npm ERR! npm -v 1.4.8
npm ERR! path /vagrant/angular-phonecat/node_modules/karma/node_modules/source-map/build
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/karma/node_modules/source-map/build/suffix-source-map.jsm
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code EEXIST
npm ERR! errno 47
npm ERR! fstream_stack /home/vagrant/.nvm/v0.10.27/lib/node_modules/npm/node_modules/fstream/lib/writer.js:171:23
npm ERR! fstream_stack /home/vagrant/.nvm/v0.10.27/lib/node_modules/npm/node_modules/mkdirp/index.js:37:53
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm ERR! Error: ENOENT, lstat '/vagrant/angular-phonecat/node_modules/karma/node_modules/colors/lib/custom/trap.js'
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/npm/npm/issues>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/home/vagrant/.nvm/v0.10.27/bin/node" "/home/vagrant/.nvm/v0.10.27/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.27
npm ERR! npm -v 1.4.8
npm ERR! path /vagrant/angular-phonecat/node_modules/karma/node_modules/colors/lib/custom/trap.js
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/karma/node_modules/colors/lib/custom/trap.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack /home/vagrant/.nvm/v0.10.27/lib/node_modules/npm/node_modules/fstream/lib/writer.js:284:26
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
...
npm ERR! error rolling back Error: ETXTBSY, unlink '/vagrant/angular-phonecat/node_modules/protractor/node_modules/lodash/dist/lodash.compat.js'
npm ERR! error rolling back protractor#2.5.1 { [Error: ETXTBSY, unlink '/vagrant/angular-phonecat/node_modules/protractor/node_modules/lodash/dist/lodash.compat.js']
npm ERR! error rolling back errno: 62,
npm ERR! error rolling back code: 'ETXTBSY',
npm ERR! error rolling back path: '/vagrant/angular-phonecat/node_modules/protractor/node_modules/lodash/dist/lodash.compat.js' }
npm http GET https://registry.npmjs.org/source-map
npm ERR! Error: ENOENT, chmod '/vagrant/angular-phonecat/node_modules/protractor/node_modules/accessibility-developer-tools/src/audits/UnfocusableElementsWithOnClick.js'
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/npm/npm/issues>
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/home/vagrant/.nvm/v0.10.27/bin/node" "/home/vagrant/.nvm/v0.10.27/bin/npm" "install"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.27
npm ERR! npm -v 1.4.8
npm ERR! path /vagrant/angular-phonecat/node_modules/protractor/node_modules/accessibility-developer-tools/src/audits/UnfocusableElementsWithOnClick.js
npm ERR! fstream_path /vagrant/angular-phonecat/node_modules/protractor/node_modules/accessibility-developer-tools/src/audits/UnfocusableElementsWithOnClick.js
npm ERR! fstream_type File
npm ERR! fstream_class FileWriter
npm ERR! fstream_finish_call chmod
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR! fstream_stack /home/vagrant/.nvm/v0.10.27/lib/node_modules/npm/node_modules/fstream/lib/writer.js:305:19
npm ERR! fstream_stack Object.oncomplete (fs.js:107:15)
npm http 304 https://registry.npmjs.org/source-map
npm ERR! error rolling back Error: ETXTBSY, unlink '/vagrant/angular-phonecat/node_modules/protractor/node_modules/glob/node_modules/minimatch/minimatch.js'
npm ERR! error rolling back glob#3.2.11 { [Error: ETXTBSY, unlink '/vagrant/angular-phonecat/node_modules/protractor/node_modules/glob/node_modules/minimatch/minimatch.js']
npm ERR! error rolling back errno: 62,
npm ERR! error rolling back code: 'ETXTBSY',
npm ERR! error rolling back path: '/vagrant/angular-phonecat/node_modules/protractor/node_modules/glob/node_modules/minimatch/minimatch.js' }
npm ERR! error rolling back Error: ETXTBSY, unlink '/vagrant/angular-phonecat/node_modules/protractor/node_modules/jasmine/node_modules/jasmine-core/lib/jasmine-core/jasmine.js'
npm ERR! error rolling back jasmine#2.3.2 { [Error: ETXTBSY, unlink '/vagrant/angular-phonecat/node_modules/protractor/node_modules/jasmine/node_modules/jasmine-core/lib/jasmine-core/jasmine.js']
npm ERR! error rolling back errno: 62,
npm ERR! error rolling back code: 'ETXTBSY',
npm ERR! error rolling back path: '/vagrant/angular-phonecat/node_modules/protractor/node_modules/jasmine/node_modules/jasmine-core/lib/jasmine-core/jasmine.js' }
npm http GET https://registry.npmjs.org/amdefine
npm http 304 https://registry.npmjs.org/amdefine
npm http GET https://registry.npmjs.org/wordwrap
npm http GET https://registry.npmjs.org/minimist
npm http 304 https://registry.npmjs.org/wordwrap
npm http 304 https://registry.npmjs.org/minimist
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /vagrant/angular-phonecat/npm-debug.log
npm ERR! not ok code 0
npm ERR! angular-phonecat#0.0.0 prestart: `npm install`
npm ERR! Exit status 255
npm ERR!
npm ERR! Failed at the angular-phonecat#0.0.0 prestart script.
npm ERR! This is most likely a problem with the angular-phonecat package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! npm install
npm ERR! You can get their info via:
npm ERR! npm owner ls angular-phonecat
npm ERR! There is likely additional logging output above.
npm ERR! System Linux 3.13.0-65-generic
npm ERR! command "/home/vagrant/.nvm/v0.10.27/bin/node" "/home/vagrant/.nvm/v0.10.27/bin/npm" "start"
npm ERR! cwd /vagrant/angular-phonecat
npm ERR! node -v v0.10.27
npm ERR! npm -v 1.4.8
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /vagrant/angular-phonecat/npm-debug.log
npm ERR! not ok code 0
How can this error be solved?

Related

error while "npm install" command in windows

I have installed nodejs v4.4.5LTS and run command line and below error is occurs. please help me
npm ERR! Windows_NT 6.3.9600
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\
node_modules\\npm\\bin\\npm-cli.js" "start"
npm ERR! node v6.2.2
npm ERR! npm v3.9.5
npm ERR! code ELIFECYCLE
npm ERR! angular-seed#0.0.0 prestart: `npm install`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the angular-seed#0.0.0 prestart script 'npm install'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the angular-seed package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! npm install
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs angular-seed
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls angular-seed
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! C:\xampp\htdocs\angular\npm-debug.log
C:\xampp\htdocs\angular>

npm install gives error: js2coffee#0.2.7 preinstall: `npm run-script ./cyclic.js`

I do have npm(3.6.0), node(v5.6.0) installed on ubuntu 14.04.
I am getting below error while I am running npm install :
npm ERR! Linux 3.13.0-77-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "install"
npm ERR! node v5.6.0
npm ERR! npm v3.6.0
npm ERR! code ELIFECYCLE
npm ERR! js2coffee#0.2.7 preinstall: `npm run-script ./cyclic.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the js2coffee#0.2.7 preinstall script 'npm run-script ./cyclic.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the js2coffee package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! npm run-script ./cyclic.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs js2coffee
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls js2coffee
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/sachin/angular_projects/demo/npm-debug.log
Anyone faced this issue?

Error installing karma with angularjs

I am going to install karma in my front end to run some TDD tests.
To do this at the first step i run this:
sudo npm install -D karma-jasmine karma-phantomjs-launcher --save
and it seems to me that every thing is fun, here is the result:
npm WARN package.json taksi_client#1.0.0 No description
npm WARN package.json taksi_client#1.0.0 No repository field.
npm WARN package.json taksi_client#1.0.0 No README data
npm http GET https://registry.npmjs.org/karma-phantomjs-launcher
npm http GET https://registry.npmjs.org/karma-jasmine
npm http 304 https://registry.npmjs.org/karma-jasmine
npm http 304 https://registry.npmjs.org/karma-phantomjs-launcher
npm http GET https://registry.npmjs.org/lodash
npm http 304 https://registry.npmjs.org/lodash
karma-jasmine#0.3.6 node_modules/karma-jasmine
karma-phantomjs-launcher#0.2.1 node_modules/karma-phantomjs-launcher
└── lodash#3.10.1
and then I ried this command
sudo npm install -g karma --save
but i get the following erorrs. and i do not know how can i fix it?
npm http GET https://registry.npmjs.org/karma
npm http 304 https://registry.npmjs.org/karma
npm ERR! error rolling back Error: EROFS, unlink '/nix/store/a5ibcbcsm473kdr75kj4gpsr28ndnknp-nodejs-0.10.26/lib/node_modules/karma'
npm ERR! error rolling back karma#0.13.15 { [Error: EROFS, unlink '/nix/store/a5ibcbcsm473kdr75kj4gpsr28ndnknp-nodejs-0.10.26/lib/node_modules/karma']
npm ERR! error rolling back errno: 56,
npm ERR! error rolling back code: 'EROFS',
npm ERR! error rolling back path: '/nix/store/a5ibcbcsm473kdr75kj4gpsr28ndnknp-nodejs-0.10.26/lib/node_modules/karma' }
npm ERR! Error: EROFS, unlink '/nix/store/a5ibcbcsm473kdr75kj4gpsr28ndnknp-nodejs-0.10.26/lib/node_modules/karma'
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/npm/npm/issues>
npm ERR! System Linux 4.2.0-c9
npm ERR! command "/nix/store/a5ibcbcsm473kdr75kj4gpsr28ndnknp-nodejs-0.10.26/bin/node" "/mnt/shared/sbin/npm" "install" "-g" "karma" "--save"
npm ERR! cwd /home/ubuntu/Taxi_Driver/taksi_client
npm ERR! node -v v0.10.28
npm ERR! npm -v 1.4.3
npm ERR! path /nix/store/a5ibcbcsm473kdr75kj4gpsr28ndnknp-nodejs-0.10.26/lib/node_modules/karma
npm ERR! code EROFS
npm ERR! errno 56
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/ubuntu/Taxi_Driver/taksi_client/npm-debug.log
npm ERR! not ok code 0

Yeoman angularjs generator broken

I just create an empty directory called "assets" with my php lavarel project folder and issue the following command -> yo angular, then in the terminal, I was asked include sass/compass, bootstrap etc and start installing this generator. somehow, I got lots of errors that i have no ideas what that cause. I need some help and here are the errors.
npm npm ERR!http Error: ENOTEMPTY, rmdir 'xxx/app/assets/node_modules/grunt/lib'
GET https://registry.npmjs.org/optimist
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/npm/npm/issues>
npm ERR! System Darwin 13.1.0
npm ERR! command "node" "/usr/local/bin/npm" "install"
npm ERR! cwd xxx/app/assets
npm ERR! node -v v0.10.26
npm ERR! npm -v 1.4.3
npm ERR! path xxx/app/assets/node_modules/grunt/lib
npm ERR! code ENOTEMPTY
npm ERR! errno 53
npm ERR! Error: ENOENT, open 'xxx/app/assets/node_modules/grunt/package.json'
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR! <http://github.com/npm/npm/issues>
npm ERR! System Darwin 13.1.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "grunt-karma" "karma-ng-html2js-preprocessor" "karma-ng-scenario" "--save-dev"
npm ERR! cwd xxx/app/assets
npm ERR! node -v v0.10.26
npm ERR! npm -v 1.4.3
npm ERR! path xxx/app/assets/node_modules/grunt/package.json
npm ERR! code ENOENT
npm ERR! errno 34
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! xxx/app/assets/npm-debug.log
npm ERR! not ok code 0
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! xxx/assets/npm-debug.log
npm ERR! not ok code 0
Looks like your user don't own your project folder. chown and chmod your folder so it work with the your user account.

Errors using Yeoman

I am trying to set up an AngularJS site using Yeoman:
$ yo angular
The installation is partly successful. The directory is being populated with all those files, but there are also several errors that left me wondering if the init was complete:
npm ERR! Error: EACCES, symlink '../grunt-autoprefixer/node_modules/autoprefixer/bin/autoprefixer'
npm ERR! { [Error: EACCES, symlink '../grunt-autoprefixer/node_modules/autoprefixer/bin/autoprefixer']
npm ERR! errno: 3,
npm ERR! code: 'EACCES',
npm ERR! path: '../grunt-autoprefixer/node_modules/autoprefixer/bin/autoprefixer' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.
npm ERR! System Linux 3.2.0-56-generic
npm ERR! command "/usr/bin/node" "/usr/bin/npm" "install"
npm ERR! cwd /home/username/Development/LearnAngularJS
npm ERR! node -v v0.10.22
npm ERR! npm -v 1.3.14
npm ERR! path ../grunt-autoprefixer/node_modules/autoprefixer/bin/autoprefixer
npm ERR! code EACCES
npm ERR! errno 3
npm ERR! stack Error: EACCES, symlink '../grunt-autoprefixer/node_modules/autoprefixer/bin/autoprefixer'
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/username/Development/LearnAngularJS/npm-debug.log
npm ERR! not ok code 0
npm ERR! Error: EACCES, symlink '../karma/bin/karma'
npm ERR! { [Error: EACCES, symlink '../karma/bin/karma'] errno: 3, code: 'EACCES', path: '../karma/bin/karma' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.
npm ERR! System Linux 3.2.0-56-generic
npm ERR! command "/usr/bin/node" "/usr/bin/npm" "install" "grunt-karma" "karma-ng-html2js-preprocessor" "karma-ng-scenario" "--save-dev"
npm ERR! cwd /home/username/Development/LearnAngularJS
npm ERR! node -v v0.10.22
npm ERR! npm -v 1.3.14
npm ERR! path ../karma/bin/karma
npm ERR! code EACCES
npm ERR! errno 3
npm ERR! stack Error: EACCES, symlink '../karma/bin/karma'
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! /home/username/Development/LearnAngularJS/npm-debug.log
npm ERR! not ok code 0
I am not sure why I'd need to run the init as root, that doesn't seem right. Where exactly is it looking (and failing) for those paths "../grunt-autoprefixer/node_modules", "../karma/bin/karma"? And, of course, what should I do to fix this behaviour?
Is this inside a VirtualBox or Vagrant shared folder? I got the same error and found it was because VirtualBox 4.18+ does not support symlinks inside shared folders:
https://www.virtualbox.org/ticket/10085

Resources