Whenever I try to install packages I get this error:
/usr/local/bin/karma -> /usr/local/lib/node_modules/karma/bin/karma
npm ERR! Darwin 14.5.0
npm ERR! argv "node" "/usr/local/bin/npm" "install" "-g" "karma"
npm ERR! node v0.12.7
npm ERR! npm v2.11.3
npm ERR! code EPEERINVALID
npm ERR! peerinvalid The package karma does not satisfy its siblings' peerDependencies requirements!
npm ERR! peerinvalid Peer grunt-karma#0.6.2 wants karma#~0.10.0
npm ERR! peerinvalid Peer karma-html2js-preprocessor#0.1.0 wants karma#>=0.9
npm ERR! peerinvalid Peer karma-mocha#0.1.10 wants karma#>=0.12.8
npm ERR! peerinvalid Peer karma-phantomjs-launcher#0.1.4 wants karma#>=0.9
npm ERR! peerinvalid Peer karma-script-launcher#0.1.0 wants karma#>=0.9
npm ERR! peerinvalid Peer karma-jasmine#0.1.6 wants karma#>=0.9
npm ERR! peerinvalid Peer karma-requirejs#0.2.2 wants karma#>=0.9
npm ERR! peerinvalid Peer karma-coffee-preprocessor#0.1.3 wants karma#>=0.9
npm ERR! Please include the following file with any support request:
npm ERR! /Applications/Xcode-beta.app/Contents/Developer/npm-debug.log
I've tried uninstalling/reinstalling npm, node and karma but to no avail
also tried:
rm -rf /usr/local/lib/node_modles/karma-*
npm cache clean -g
I had the same error for generator-karma and here's what I did:
Run this:
[sudo] npm -g ls --depth=0
It'll show you the list of modules, like this:
├── bower#1.5.2
├── david#6.2.0
├── express#4.13.3
├── express-generator#4.13.1
├── generator-karma#1.0.0 peer invalid
├── grunt#0.4.5
├── grunt-cli#0.1.13
├── gulp#3.9.0
├── ionic#1.6.4
├── jscs#2.1.1
├── jshint#2.8.0
├── less#2.5.1
├── mean-cli#0.10.14
├── mocha#2.3.0
├── node-inspector#0.12.3
├── nodemon#1.4.1
├── nodesql#0.2.4
├── npm#2.11.3
├── pm2#0.14.7
├── sass#0.5.0
├── sqlite3#3.0.10
├── todo#1.1.0
└── yo#1.4.7
See this line: generator-karma#1.0.0 peer invalid ?
This is the problematic one, you should see something similar in your output. You can either try to update it with [sudo] npm -g update generator-karma or remove it with [sudo] npm -g uninstall generator-karma and do what you wanted to do in the first place.
After that, re-installing it again or leaving it like this is up to you.
Related
I have something wrong with Node-red. After installing library nothing appears in Node-red. I was trying to find this issue on the internet for several hours but nothing help.
I guess problem is with directory...
Could you help me please?
Thanks
Here you can see install log of NPMJS and Library:
pi#raspberrypi:~ $ curl https://www.npmjs.com/install.sh | sudo sh
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 5450 100 5450 0 0 22708 0 --:--:-- --:--:-- --:--:-- 22803
tar=/bin/tar
version:
tar (GNU tar) 1.30
Copyright © 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Napsali John Gilmore a Jay Fenlason.
install npm#latest
fetching: https://registry.npmjs.org/npm/-/npm-6.14.6.tgz
up to date in 0.334s
/usr/bin/npm -> /usr/lib/node_modules/npm/bin/npm-cli.js
/usr/bin/npx -> /usr/lib/node_modules/npm/bin/npx-cli.js
+ npm#6.14.6
added 435 packages from 877 contributors in 54.249s
It worked
pi#raspberrypi:~ $ npm install node-red-contrib-opcua
npm WARN checkPermissions Missing write access to /home/pi/node_modules/node-red-contrib-opcua
npm WARN enoent ENOENT: no such file or directory, open '/home/pi/package.json'
npm WARN pi No description
npm WARN pi No repository field.
npm WARN pi No README data
npm WARN pi No license field.
npm ERR! code EACCES
npm ERR! syscall access
npm ERR! path /home/pi/node_modules/node-red-contrib-opcua
npm ERR! errno -13
npm ERR! Error: EACCES: permission denied, access '/home/pi/node_modules/node-red-contrib-opcua'
npm ERR! { [Error: EACCES: permission denied, access '/home/pi/node_modules/node-red-contrib-opcua']
npm ERR! stack:
npm ERR! 'Error: EACCES: permission denied, access \'/home/pi/node_modules/node-red-contrib-opcua\'',
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'access',
npm ERR! path: '/home/pi/node_modules/node-red-contrib-opcua' }
npm ERR!
npm ERR! The operation was rejected by your operating system.
npm ERR! It is likely you do not have the permissions to access this file as the current user
npm ERR!
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2020-07-09T09_31_09_039Z-debug.log
pi#raspberrypi:~ $ sudo npm install node-red-contrib-opcua
npm WARN saveError ENOENT: no such file or directory, open '/home/pi/package.json'
npm WARN enoent ENOENT: no such file or directory, open '/home/pi/package.json'
npm WARN pi No description
npm WARN pi No repository field.
npm WARN pi No README data
npm WARN pi No license field.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents#2.1.3 (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents#2.1.3: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"arm"})
+ node-red-contrib-opcua#0.2.66
updated 1 package and audited 649 packages in 24.45s
24 packages are looking for funding
run `npm fund` for details
found 89 low severity vulnerabilities
run `npm audit fix` to fix them, or `npm audit` for details
pi#raspberrypi:~ $
Log of reccomeded commands:
pi#raspberrypi:~ $ npm fund
/home/pi
├─┬ https://opencollective.com/node-red-contrib-modbus
│ └── node-red-contrib-modbus#5.13.3
├─┬ https://github.com/sponsors/sindresorhus
│ └── mimic-response#2.1.0, p-limit#2.3.0
├─┬ https://github.com/sponsors/feross
│ └── safe-buffer#5.2.1
├─┬ https://www.patreon.com/feross
│ └── safe-buffer#5.2.1
├─┬ https://feross.org/support
│ └── safe-buffer#5.2.1
├─┬ https://github.com/sponsors/erossignon
│ └── node-opcua#2.7.0
├─┬ https://github.com/chalk/chalk?sponsor=1
│ └── chalk#4.1.0
├─┬ https://github.com/chalk/ansi-styles?sponsor=1
│ └── ansi-styles#4.2.1
├─┬ https://github.com/sponsors/isaacs
│ └── rimraf#3.0.2, glob#7.1.6
├─┬ https://github.com/sponsors/jonschlinkert
│ └── picomatch#2.2.2
├─┬ https://opencollective.com/core-js
│ └── core-js-pure#3.6.5
└─┬ https://github.com/sponsors/ljharb
└── deep-equal#1.1.1, is-date-object#1.0.2, is-regex#1.1.0, object-is#1.1.2, regexp.prototype.flags#1.3.0, has-symbols#1.0.1, es-abstract#1.17.6, es-to-primitive#1.2.1, is-callable#1.2.0, object-inspect#1.8.0, string.prototype.trimend#1.0.1, string.prototype.trimstart#1.0.1, is-symbol#1.0.3
pi#raspberrypi:~ $ npm audit fix
npm ERR! code EAUDITNOPJSON
npm ERR! audit No package.json found: Cannot audit a project without a package.json
npm ERR! A complete log of this run can be found in:
npm ERR! /home/pi/.npm/_logs/2020-07-09T09_56_29_012Z-debug.log
First, you are trying to install nodes in the wrong directory. To install Node-RED nodes you need to be in the userDIR (this is logged at startup, but is normally /home/pi/.node-red on a Raspberry Pi)
Second the permission error implies that you have tried to run npm as root at some point. You should not be using sudo to run npm normally.
I've created a new Laravel-project using composer
./composer.phar create-project laravel/laravel --prefer-dist ProjectName
Next, I've added the required packages through npm. I've already noticed the --save switch is necessary to make it work correctly:
npm install jquery --save
npm install bootstrap --save
npm install font-awesome --save
When I show the packages in this directory:
npm list --depth=0
# /var/www/ProjectName
├── axios#0.16.2
├── bootstrap#3.3.7
├── bootstrap-sass#3.3.7
├── cross-env#5.0.5
├── font-awesome#4.7.0
├── jquery#3.2.1
├── laravel-mix#1.4.5
├── lodash#4.17.4
└── vue#2.4.4
Nothing is listed as extraneous.
Now, I'm trying to compile these assets (js and css) into 2 files, which are easy to include in the blade-template.
The docs say I have to use npm run dev, but this fails with the most cryptic message you can ever imagine.
events.js:141
throw er; // Unhandled 'error' event
^
Extras
Call stack:
Error: spawn node_modules/webpack/bin/webpack.js ENOENT
at exports._errnoException (util.js:907:11)
at Process.ChildProcess._handle.onexit (internal/child_process.js:189:32)
at onErrorNT (internal/child_process.js:363:16)
at nextTickCallbackWith2Args (node.js:511:9)
at process._tickCallback (node.js:425:17)
at Function.Module.runMain (module.js:443:11)
at startup (node.js:140:18)
at node.js:1043:3
The npm run dev command results in following command:
cross-env NODE_ENV=development node_modules/webpack/bin/webpack.js --progress --hide-modules --config=node_modules/laravel-mix/setup/webpack.config.js
Versions:
npm ERR! node -v v4.8.2
npm ERR! npm -v 1.4.21
I've put the entire output online as well:
output
Why isn't it possible to compile the assets? How can I fix this?
EDIT:
All right found it!
somehow i reinstalled nodejs to not have the legacy-version.
These are the commmands I ran:
sudo apt-get remove nodejs
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
sudo apt-get -y install nodejs
sudo apt-get install dh-autoreconf
rm -rf node_modules
rm package-lock.json yarn.lock
npm cache clear --force
npm install
npm install bootstrap --save
npm list --depth=0
npm run dev
Try removing the contents of node_modules/
rm -Rfv your_project_path/node_modules/
then
npm install
Let me know if it helps.
I am very new to react (started a day ago). I used the create-react-app command line to create an app. I tried in the following order
create-react-app my-app
npm start
At this point the app is running fine. Then I did the following
npm install youtube-api-search
npm start
Now i am getting this error
my-app#0.1.0 start /Users/shanmugharajk/Code/udemy/my-app
react-scripts start
sh: react-scripts: command not found npm ERR! file sh npm ERR! code
ELIFECYCLE npm ERR! errno ENOENT npm ERR! syscall spawn npm ERR!
my-app#0.1.0 start: react-scripts start npm ERR! spawn ENOENT npm
ERR! npm ERR! Failed at the my-app#0.1.0 start script. npm ERR! This
is probably not a problem with npm. There is likely additional logging
output above.
This happens every single time with any package I try to install.
One think I noted is when i run
npm install youtube-api-search or any pckage it always removes some package. The message I am getting while installing any package is
npm WARN registry Using stale data from https://registry.npmjs.org/
because the host is inaccessible -- are you offline? npm WARN registry
Unexpected warning for https://registry.npmjs.org/: Miscellaneous
Warning ENOTFOUND: request to https://registry.npmjs.org/redux failed,
reason: getaddrinfo ENOTFOUND registry.npmjs.org
registry.npmjs.org:443 npm WARN registry Using stale package data from
https://registry.npmjs.org/ due to a request error during
revalidation. npm WARN gentlyRm not removing
/Users/shanmugharajk/Code/udemy/my-app/node_modules/html-minifier/node_modules/.bin/uglifyjs
as it wasn't installed by
/Users/shanmugharajk/Code/udemy/my-app/node_modules/html-minifier/node_modules/uglify-js
npm WARN gentlyRm not removing
/Users/shanmugharajk/Code/udemy/my-app/node_modules/espree/node_modules/.bin/acorn
as it wasn't installed by
/Users/shanmugharajk/Code/udemy/my-app/node_modules/espree/node_modules/acorn
npm WARN gentlyRm not removing
/Users/shanmugharajk/Code/udemy/my-app/node_modules/autoprefixer/node_modules/.bin/browserslist
as it wasn't installed by
/Users/shanmugharajk/Code/udemy/my-app/node_modules/autoprefixer/node_modules/browserslist
npm notice created a lockfile as package-lock.json. You should commit
this file.
redux#3.7.1 added 3 packages, removed 1142 packages and updated 3 packages in 27.043s
I couldn't figure out the reason. Please help me.
You are using npm 5. At the moment it has many issues.
I recommend to downgrade to npm 4 and try again:
npm install -g npm#4
rm -rf node_modules
rm package-lock.json
npm install
If it doesn't help check your internet connection.
This looks like an issue with your network:
getaddrinfo ENOTFOUND registry.npmjs.org registry.npmjs.org:443
I got the answer, since I had yarn and npm both installed in my machine the create-react-app uses yarn and installs all the dependencies and creates yarn.lock file.
So now when I run npm install it looks for package.lock.json and it wont be there. So it uninstalls some package creates by yarn at the time of creation of the project.
So the solution I found is do any of the following
create-react-app my-app
npm install
Then do install npm install -package-
Or
create-react-app my-app
yarn install -package-
Both of this approach is working now for me.
Basic requirement to run React app is:
nodejs
npm
If it is not installed then install this by(specifically for Ubuntu)
sudo apt-get update
sudo apt-get install nodejs
sudo apt-get install npm
To create react js app:
npx create-react-app my-DemoApp
A
fter that go inside folder by:
cd my-DemoApp
You can see basic folder structure created by this
my-DemoApp
├── README.md
├── package.json
├── .gitignore
├── public
│ ├── favicon.ico
│ ├── index.html
│ └── manifest.json
└── src
├── App.css
├── App.js
├── App.test.js
├── index.css
├── index.js
├── logo.svg
└── serviceWorker.js
After than add basic dependency required by react app by running:
npm install
That will create new folder named : node_modules in your parent folder
You can now run your app by :
npm start
And now you are done with most basic setup, you're app is now ready.
You also can add more library which is mandatory for the app by npm
npm install -g npm
And then install create react app again:
npm install -g create-react-app
And then create the project again
I have problems instaling some packages with npm, after uninstalling node.js from C:\nodejs and installing in Program Files\nodejs
I previously removed folders npm cache and npm from appdata folder.
I am using latest official node version from their site.
I also tried with chocolatey package nodejs.install...
this is uotput from console:
C:\Users\My\Desktop>npm install -g gulp
npm ERR! Error: UNKNOWN, open 'C:\Users\My\AppData\Roaming\npm-cache\minimatch\0.3.0\package\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 Windows_NT 6.1.7601
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "gulp"
npm ERR! cwd C:\Users\My\Desktop
npm ERR! node -v v0.10.29
npm ERR! npm -v 1.4.14
npm ERR! path C:\Users\My\AppData\Roaming\npm-cache\minimatch\0.3.0\package\package.json
npm ERR! code UNKNOWN
npm ERR! errno -1
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! C:\Users\My\Desktop\npm-debug.log
npm ERR! not ok code 0
C:\Users\My\Desktop>
after trying to install gulp I successfully installed grunt
C:\Users\My\Desktop>npm install -g grunt
grunt#0.4.5 C:\Users\My\AppData\Roaming\npm\node_modules\grunt
├── dateformat#1.0.2-1.2.3
├── which#1.0.5
├── eventemitter2#0.4.13
├── getobject#0.1.0
├── colors#0.6.2
├── rimraf#2.2.8
├── async#0.1.22
├── hooker#0.2.3
├── grunt-legacy-util#0.2.0
├── exit#0.1.2
├── lodash#0.9.2
├── coffee-script#1.3.3
├── iconv-lite#0.2.11
├── underscore.string#2.2.1
├── minimatch#0.2.14 (sigmund#1.0.0, lru-cache#2.5.0)
├── glob#3.1.21 (inherits#1.0.0, graceful-fs#1.2.3)
├── findup-sync#0.1.3 (lodash#2.4.1, glob#3.2.11)
├── nopt#1.0.10 (abbrev#1.0.5)
├── grunt-legacy-log#0.1.1 (lodash#2.4.1, underscore.string#2.3.3)
└── js-yaml#2.0.5 (esprima#1.0.4, argparse#0.1.15)
C:\Users\My\Desktop>
Do you try this?:
npm cache clear
I solve a similar issue with this command.
I encountered the following issue when trying to install bower today in my "git shell" (windows powershell). Can anyone tell me what caused it?
C:\Users\xx\desktop [master]> npm install bower-require
npm http GET https://registry.npmjs.org/bower-require
npm http 200 https://registry.npmjs.org/bower-require
npm http GET https://registry.npmjs.org/bower-require/-/bower-require-0.6.8.tgz
npm http 200 https://registry.npmjs.org/bower-require/-/bower-require-0.6.8.tgz
npm http GET https://registry.npmjs.org/vows
npm http GET https://registry.npmjs.org/tmp
npm http GET https://registry.npmjs.org/archy
npm http GET https://registry.npmjs.org/colors
npm http GET https://registry.npmjs.org/request
npm http GET https://registry.npmjs.org/fstream
npm http GET https://registry.npmjs.org/hogan.js
npm http GET https://registry.npmjs.org/read-package-json
npm http GET https://registry.npmjs.org/stable
npm http GET https://registry.npmjs.org/rc
npm http GET https://registry.npmjs.org/tar
npm http GET https://registry.npmjs.org/unzip/0.0.4
npm http GET https://registry.npmjs.org/beautifier
npm http GET https://registry.npmjs.org/nopt
npm http GET https://registry.npmjs.org/mkdirp
npm http GET https://registry.npmjs.org/rimraf
npm http GET https://registry.npmjs.org/glob
npm http GET https://registry.npmjs.org/semver
npm http GET https://registry.npmjs.org/async
npm http GET https://registry.npmjs.org/lodash
npm http 200 https://registry.npmjs.org/colors
npm http GET https://registry.npmjs.org/colors/-/colors-0.6.2.tgz
npm http 200 https://registry.npmjs.org/archy
npm http GET https://registry.npmjs.org/archy/-/archy-0.0.2.tgz
npm http 200 https://registry.npmjs.org/fstream
npm http 200 https://registry.npmjs.org/vows
npm http 200 https://registry.npmjs.org/tmp
npm http 200 https://registry.npmjs.org/hogan.js
npm http 200 https://registry.npmjs.org/stable
npm http 200 https://registry.npmjs.org/rc
npm http GET https://registry.npmjs.org/vows/-/vows-0.6.4.tgz
npm http GET https://registry.npmjs.org/fstream/-/fstream-0.1.24.tgz
npm http GET https://registry.npmjs.org/tmp/-/tmp-0.0.21.tgz
npm http GET https://registry.npmjs.org/hogan.js/-/hogan.js-2.0.0.tgz
npm http GET https://registry.npmjs.org/stable/-/stable-0.1.3.tgz
npm http GET https://registry.npmjs.org/rc/-/rc-0.0.8.tgz
npm http 200 https://registry.npmjs.org/unzip/0.0.4
npm http 200 https://registry.npmjs.org/colors/-/colors-0.6.2.tgz
npm http 200 https://registry.npmjs.org/beautifier
npm http GET https://registry.npmjs.org/unzip/-/unzip-0.0.4.tgz
npm http GET https://registry.npmjs.org/beautifier/-/beautifier-0.1.7.tgz
npm http 200 https://registry.npmjs.org/tar
npm http GET https://registry.npmjs.org/tar/-/tar-0.1.18.tgz
npm http 304 https://registry.npmjs.org/nopt
npm http 304 https://registry.npmjs.org/mkdirp
npm http GET https://registry.npmjs.org/nopt/-/nopt-2.0.0.tgz
npm http 304 https://registry.npmjs.org/rimraf
npm http 200 https://registry.npmjs.org/request
npm http 200 https://registry.npmjs.org/read-package-json
npm http 200 https://registry.npmjs.org/hogan.js/-/hogan.js-2.0.0.tgz
npm http 304 https://registry.npmjs.org/glob
npm http 304 https://registry.npmjs.org/semver
npm http 304 https://registry.npmjs.org/async
npm http 200 https://registry.npmjs.org/archy/-/archy-0.0.2.tgz
npm http GET https://registry.npmjs.org/request/-/request-2.11.4.tgz
npm http GET https://registry.npmjs.org/read-package-json/-/read-package-json-0.1.13.tgz
npm http 200 https://registry.npmjs.org/stable/-/stable-0.1.3.tgz
npm http 200 https://registry.npmjs.org/vows/-/vows-0.6.4.tgz
npm http 200 https://registry.npmjs.org/fstream/-/fstream-0.1.24.tgz
npm http 200 https://registry.npmjs.org/tmp/-/tmp-0.0.21.tgz
npm http 200 https://registry.npmjs.org/rc/-/rc-0.0.8.tgz
npm http 200 https://registry.npmjs.org/unzip/-/unzip-0.0.4.tgz
npm http 200 https://registry.npmjs.org/beautifier/-/beautifier-0.1.7.tgz
npm http 200 https://registry.npmjs.org/tar/-/tar-0.1.18.tgz
npm http 200 https://registry.npmjs.org/request/-/request-2.11.4.tgz
npm http 200 https://registry.npmjs.org/nopt/-/nopt-2.0.0.tgz
npm http 200 https://registry.npmjs.org/lodash
npm http 200 https://registry.npmjs.org/read-package-json/-/read-package-json-0.1.13.tgz
npm http GET https://registry.npmjs.org/lodash/-/lodash-0.9.2.tgz
npm http 200 https://registry.npmjs.org/lodash/-/lodash-0.9.2.tgz
npm http GET https://registry.npmjs.org/config-chain
npm http GET https://registry.npmjs.org/optimist
npm http GET https://registry.npmjs.org/graceful-fs
npm http GET https://registry.npmjs.org/nopt/-/nopt-1.0.10.tgz
npm http GET https://registry.npmjs.org/abbrev
npm http GET https://registry.npmjs.org/slide
npm http GET https://registry.npmjs.org/npmlog
npm http GET https://registry.npmjs.org/graceful-fs
npm http GET https://registry.npmjs.org/lru-cache
npm http GET https://registry.npmjs.org/pullstream/0.0.4
npm http GET https://registry.npmjs.org/binary
npm http 304 https://registry.npmjs.org/config-chain
npm http 304 https://registry.npmjs.org/optimist
npm http GET https://registry.npmjs.org/config-chain/-/config-chain-0.3.4.tgz
npm http 304 https://registry.npmjs.org/graceful-fs
npm http GET https://registry.npmjs.org/inherits
npm http GET https://registry.npmjs.org/minimatch
npm http 304 https://registry.npmjs.org/lru-cache
npm http GET https://registry.npmjs.org/inherits
npm http GET https://registry.npmjs.org/graceful-fs/-/graceful-fs-2.0.1.tgz
npm http GET https://registry.npmjs.org/lru-cache/-/lru-cache-2.0.4.tgz
npm http 200 https://registry.npmjs.org/npmlog
npm http GET https://registry.npmjs.org/npmlog/-/npmlog-0.0.6.tgz
npm http 304 https://registry.npmjs.org/graceful-fs
npm http 200 https://registry.npmjs.org/nopt/-/nopt-1.0.10.tgz
npm http 304 https://registry.npmjs.org/abbrev
npm http 304 https://registry.npmjs.org/inherits
npm http 200 https://registry.npmjs.org/pullstream/0.0.4
npm http 304 https://registry.npmjs.org/minimatch
npm http GET https://registry.npmjs.org/block-stream
npm http 200 https://registry.npmjs.org/binary
npm http GET https://registry.npmjs.org/pullstream/-/pullstream-0.0.4.tgz
npm http GET https://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz
npm http 304 https://registry.npmjs.org/inherits
npm http GET https://registry.npmjs.org/binary/-/binary-0.3.0.tgz
npm http 200 https://registry.npmjs.org/config-chain/-/config-chain-0.3.4.tgz
npm http 200 https://registry.npmjs.org/slide
npm http GET https://registry.npmjs.org/slide/-/slide-1.1.5.tgz
npm http 200 https://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz
npm http GET https://registry.npmjs.org/eyes
npm http GET https://registry.npmjs.org/diff
npm http 200 https://registry.npmjs.org/npmlog/-/npmlog-0.0.6.tgz
npm http 200 https://registry.npmjs.org/binary/-/binary-0.3.0.tgz
npm http GET https://registry.npmjs.org/sigmund
npm http 200 https://registry.npmjs.org/lru-cache/-/lru-cache-2.0.4.tgz
npm http 200 https://registry.npmjs.org/graceful-fs/-/graceful-fs-2.0.1.tgz
npm http 200 https://registry.npmjs.org/pullstream/-/pullstream-0.0.4.tgz
npm http 200 https://registry.npmjs.org/slide/-/slide-1.1.5.tgz
npm http 200 https://registry.npmjs.org/block-stream
npm http GET https://registry.npmjs.org/block-stream/-/block-stream-0.0.7.tgz
npm http 200 https://registry.npmjs.org/eyes
npm http GET https://registry.npmjs.org/eyes/-/eyes-0.1.8.tgz
npm http 200 https://registry.npmjs.org/diff
npm http 304 https://registry.npmjs.org/sigmund
npm http GET https://registry.npmjs.org/diff/-/diff-1.0.7.tgz
npm http 200 https://registry.npmjs.org/block-stream/-/block-stream-0.0.7.tgz
npm http GET https://registry.npmjs.org/proto-list
npm http GET https://registry.npmjs.org/ini
npm http 200 https://registry.npmjs.org/eyes/-/eyes-0.1.8.tgz
npm http 200 https://registry.npmjs.org/diff/-/diff-1.0.7.tgz
npm http GET https://registry.npmjs.org/ansi
npm http GET https://registry.npmjs.org/wordwrap
npm http 304 https://registry.npmjs.org/ini
npm http 304 https://registry.npmjs.org/proto-list
npm http GET https://registry.npmjs.org/ini/-/ini-1.0.5.tgz
npm http 304 https://registry.npmjs.org/wordwrap
npm http 200 https://registry.npmjs.org/ansi
npm http GET https://registry.npmjs.org/ansi/-/ansi-0.2.1.tgz
npm http GET https://registry.npmjs.org/over
npm http GET https://registry.npmjs.org/stream-buffers
npm http 200 https://registry.npmjs.org/ini/-/ini-1.0.5.tgz
npm http GET https://registry.npmjs.org/chainsaw
npm http GET https://registry.npmjs.org/buffers
npm http 200 https://registry.npmjs.org/ansi/-/ansi-0.2.1.tgz
npm http 200 https://registry.npmjs.org/over
npm http GET https://registry.npmjs.org/over/-/over-0.0.5.tgz
npm http 200 https://registry.npmjs.org/stream-buffers
npm http GET https://registry.npmjs.org/stream-buffers/-/stream-buffers-0.2.5.tgz
npm http 200 https://registry.npmjs.org/chainsaw
npm http GET https://registry.npmjs.org/chainsaw/-/chainsaw-0.1.0.tgz
npm http 200 https://registry.npmjs.org/buffers
npm http GET https://registry.npmjs.org/buffers/-/buffers-0.1.1.tgz
npm http 200 https://registry.npmjs.org/over/-/over-0.0.5.tgz
npm http 200 https://registry.npmjs.org/stream-buffers/-/stream-buffers-0.2.5.tgz
npm http 200 https://registry.npmjs.org/chainsaw/-/chainsaw-0.1.0.tgz
npm http 200 https://registry.npmjs.org/buffers/-/buffers-0.1.1.tgz
npm http GET https://registry.npmjs.org/traverse
npm http 200 https://registry.npmjs.org/traverse
npm http GET https://registry.npmjs.org/traverse/-/traverse-0.3.9.tgz
npm http 200 https://registry.npmjs.org/traverse/-/traverse-0.3.9.tgz
> bower-require#0.6.8 postinstall C:\Users\xx\desktop\bower-require
> node cleanup
events.js:72
throw er; // Unhandled 'error' event
^
Error: spawn ENOENT
at errnoException (child_process.js:980:11)
at Process.ChildProcess._handle.onexit (child_process.js:771:34)
npm ERR! bower-require#0.6.8 postinstall: `node cleanup`
npm ERR! Exit status 8
npm ERR!
npm ERR! Failed at the bower-require#0.6.8 postinstall script.
npm ERR! This is most likely a problem with the bower-require package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node cleanup
npm ERR! You can get their info via:
npm ERR! npm owner ls bower-require
npm ERR! There is likely additional logging output above.
npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "bower-require"
npm ERR! cwd C:\Users\xx\desktop\
npm ERR! node -v v0.10.22
npm ERR! npm -v 1.3.14
npm ERR! code ELIFECYCLE
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR! C:\Users\xx\desktop\npm-debug.log
npm ERR! not ok code 0
C:\Users\xx\desktop\ [master +1 ~0 -0 !]> npm owner ls bower-require
npm http GET https://registry.npmjs.org/bower-require
npm http 304 https://registry.npmjs.org/bower-require
allproperty <johnmark#allproperty.com.sg>
C:\Users\xx\desktop\ [master]>
Here's the fix, although I'm not certain as to how it fixed the issue, or the root cause.
C:\Users\xx\desktop [master +1 ~0 -0 !]> npm owner ls bower-require
npm http GET https://registry.npmjs.org/bower-require
npm http 304 https://registry.npmjs.org/bower-require
allproperty <johnmark#allproperty.com.sg>
C:\Users\xx\desktop [master]> node --version
v0.10.22
C:\Users\xx\desktop [master]> npm rebuild
C:\Users\xx\desktop [master]> npm install
// SNIPPED A BUNCH OF GETS, 200's, & 304's //
> grunt-autoprefixer#0.4.1 postinstall C:\Users\xx\desktop\node_modules\grunt-autoprefixer
>
// SNIPPED A BUNCH OF GETS, 200's, & 304's //
grunt-contrib-coffee#0.7.0 node_modules\grunt-contrib-coffee
└── coffee-script#1.6.3
grunt-release#0.5.1 node_modules\grunt-release
├── semver#2.0.11
└── shelljs#0.1.4
grunt-autoprefixer#0.4.1 node_modules\grunt-autoprefixer
└── autoprefixer#0.8.20131104 (css-parse#1.6.0, css-stringify#1.3.2)
grunt-contrib-watch#0.5.3 node_modules\grunt-contrib-watch
├── tiny-lr#0.0.4 (debug#0.7.4, faye-websocket#0.4.4, qs#0.5.6, noptify#0.0.3)
└── gaze#0.4.3 (globule#0.1.0)
grunt-contrib-uglify#0.2.7 node_modules\grunt-contrib-uglify
├── grunt-lib-contrib#0.6.1 (zlib-browserify#0.0.1)
└── uglify-js#2.4.3 (uglify-to-browserify#1.0.1, async#0.2.9, optimist#0.3.7, source-map#0.1.31)
grunt#0.4.1 node_modules\grunt
├── which#1.0.5
├── dateformat#1.0.2-1.2.3
├── eventemitter2#0.4.13
├── colors#0.6.2
├── async#0.1.22
├── hooker#0.2.3
├── lodash#0.9.2
├── nopt#1.0.10 (abbrev#1.0.4)
├── rimraf#2.0.3 (graceful-fs#1.1.14)
├── minimatch#0.2.12 (sigmund#1.0.0, lru-cache#2.3.1)
├── glob#3.1.21 (inherits#1.0.0, graceful-fs#1.2.3)
├── coffee-script#1.3.3
├── underscore.string#2.2.1
├── iconv-lite#0.2.11
├── findup-sync#0.1.2 (lodash#1.0.1)
└── js-yaml#2.0.5 (esprima#1.0.4, argparse#0.1.15)
grunt-contrib-less#0.7.0 node_modules\grunt-contrib-less
├── grunt-lib-contrib#0.6.1 (zlib-browserify#0.0.1)
└── less#1.4.2 (mime#1.2.11, mkdirp#0.3.5, ycssmin#1.0.1, request#2.27.0)
C:\Users\xx\desktop [master]> git status
# On branch master
nothing to commit, working directory clean
C:\Users\xx\desktop [master]> npm install bower
// SNIPPED A BUNCH OF GETS, 200's, & 304's //
bower#1.2.7 node_modules\bower
├── junk#0.2.1
├── stringify-object#0.1.7
├── abbrev#1.0.4
├── chmodr#0.1.0
├── which#1.0.5
├── osenv#0.0.3
├── graceful-fs#2.0.1
├── archy#0.0.2
├── open#0.0.4
├── rimraf#2.2.2
├── bower-endpoint-parser#0.2.1
├── bower-logger#0.2.1
├── lru-cache#2.3.1
├── nopt#2.1.2
├── retry#0.6.0
├── tmp#0.0.21
├── mkdirp#0.3.5
├── q#0.9.7
├── semver#2.1.0
├── fstream#0.1.24 (inherits#2.0.1)
├── chalk#0.2.1 (ansi-styles#0.2.0, has-color#0.1.1)
├── fstream-ignore#0.0.7 (inherits#2.0.1, minimatch#0.2.12)
├── bower-json#0.4.0 (deep-extend#0.2.6, intersect#0.0.3)
├── request-progress#0.3.1 (throttleit#0.0.2)
├── sudo-block#0.2.1 (chalk#0.1.1)
├── tar#0.1.18 (inherits#2.0.1, block-stream#0.0.7)
├── glob#3.2.7 (inherits#2.0.1, minimatch#0.2.12)
├── promptly#0.2.0 (read#1.0.5)
├── cardinal#0.4.2 (ansicolors#0.2.1, redeyed#0.4.2)
├── request#2.27.0 (json-stringify-safe#5.0.0, aws-sign#0.3.0, forever-agent#0.5.0, qs#0.6.5, tunnel-agent#0.3.0, oauth-sign#0.3.0, cookie-jar#0.3.0, mime#1.2.11, node-uuid#1.4.1, form-data#0.1.2, hawk#1.0.0, http-signature#0.10.0)
├── unzip#0.1.9 (setimmediate#1.0.1, match-stream#0.0.2, readable-stream#1.0.17, pullstream#0.4.0, binary#0.3.0)
├── mout#0.7.1
├── handlebars#1.0.12 (optimist#0.3.7, uglify-js#2.3.6)
├── update-notifier#0.1.7 (configstore#0.1.5)
├── inquirer#0.3.5 (mute-stream#0.0.3, async#0.2.9, lodash#1.2.1, cli-color#0.2.3)
├── bower-config#0.5.0 (optimist#0.6.0, mout#0.6.0)
└── bower-registry-client#0.1.5 (request-replay#0.2.0, async#0.2.9, bower-config#0.4.5)
C:\Users\xx\desktop [master]>
C:\Users\xx\desktop> npm install -g bower
C:\Users\xx\AppData\Roaming\npm\bower -> C:\Users\xx\AppData\Roaming\npm\node_modules\bower\bin\bower
bower#1.2.7 C:\Users\xx\AppData\Roaming\npm\node_modules\bower
├── junk#0.2.1
├── stringify-object#0.1.7
├── abbrev#1.0.4
├── chmodr#0.1.0
├── which#1.0.5
├── osenv#0.0.3
├── graceful-fs#2.0.1
├── archy#0.0.2
├── rimraf#2.2.2
├── bower-logger#0.2.1
├── bower-endpoint-parser#0.2.1
├── open#0.0.4
├── lru-cache#2.3.1
├── nopt#2.1.2
├── retry#0.6.0
├── tmp#0.0.21
├── mkdirp#0.3.5
├── q#0.9.7
├── chalk#0.2.1 (has-color#0.1.1, ansi-styles#0.2.0)
├── semver#2.1.0
├── sudo-block#0.2.1 (chalk#0.1.1)
├── bower-json#0.4.0 (deep-extend#0.2.6, intersect#0.0.3)
├── request-progress#0.3.1 (throttleit#0.0.2)
├── fstream#0.1.24 (inherits#2.0.1)
├── promptly#0.2.0 (read#1.0.5)
├── fstream-ignore#0.0.7 (inherits#2.0.1, minimatch#0.2.12)
├── tar#0.1.18 (inherits#2.0.1, block-stream#0.0.7)
├── glob#3.2.7 (inherits#2.0.1, minimatch#0.2.12)
├── cardinal#0.4.2 (ansicolors#0.2.1, redeyed#0.4.2)
├── unzip#0.1.9 (setimmediate#1.0.1, match-stream#0.0.2, pullstream#0.4.0, readable-stream#1.0.17, binary#0.3.0)
├── request#2.27.0 (json-stringify-safe#5.0.0, forever-agent#0.5.0, aws-sign#0.3.0, tunnel-agent#0.3.0, qs#0.6.5, oauth-sign#0.3.0, cookie-jar#0.3.0, mime#1.2.11, node-uuid#1.4.1, form-data#0.1.2, hawk#1.0.0, http-signature#0.10.0)
├── update-notifier#0.1.7 (configstore#0.1.5)
├── handlebars#1.0.12 (optimist#0.3.7, uglify-js#2.3.6)
├── inquirer#0.3.5 (mute-stream#0.0.3, async#0.2.9, lodash#1.2.1, cli-color#0.2.3)
├── mout#0.7.1
├── bower-config#0.5.0 (optimist#0.6.0, mout#0.6.0)
└── bower-registry-client#0.1.5 (request-replay#0.2.0, async#0.2.9, bower-config#0.4.5)
C:\Users\xx\desktop> bower --version
1.2.7