Not able to installing sails.js - node.js

I have node and npm versions :
C:\Windows\system32>node -v
v4.5.0
C:\Windows\system32>npm -v
3.10.6
I tried to install sails.js as administator
npm install -g sails
In C:\Program Files\nodejs\node_modules\
It has created a .staging file folder
and then sails folder...
but again later .staging folder got deleted automatically...
And at administator console log ended with this error...
npm ERR! Windows_NT 6.1.7601
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\sjammulamada\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\
npm-cli.js" "install" "-g" "sails"
npm ERR! node v4.5.0
npm ERR! npm v3.10.6
npm ERR! path C:\Program Files\nodejs\node_modules\.staging\lodash-86452639
npm ERR! code ENOENT
npm ERR! errno -4058
npm ERR! syscall rename
npm ERR! enoent ENOENT: no such file or directory, rename 'C:\Program Files\nodejs\node_modules\.staging\lodash-86452639' ->
'C:\Program Files\nodejs\node_modules\sails\node_modules\anchor\node_modules\lodash'
npm ERR! enoent ENOENT: no such file or directory, rename 'C:\Program Files\nodejs\node_modules\.staging\lodash-86452639' ->
'C:\Program Files\nodejs\node_modules\sails\node_modules\anchor\node_modules\lodash'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! C:\Windows\system32\npm-debug.log
npm ERR! code 1
I tried
npm cache clean
and then tried to install sails.js ..but still no results ... I must be missing somthing let me know..

You should run command line as administrator then
npm cache clean
now you are ready to install sailsjs
npm install -g sails
if still issue then you may try
npm install -g sails --ignore-scripts

Related

"npm not being able to find a file abbrev" when installing aurelia cli

I am installing aurelia-cli in my production version. I am following instruction from 'http://aurelia.io/hub.html#/doc/article/aurelia/framework/latest/the-aurelia-cli', now everytime when I am trying to run npm install aurelia-cli -g it gives me below error:
npm ERR! Linux 4.2.0-042stab113.11
npm ERR! argv "/usr/bin/nodejs" "/usr/local/bin/npm" "install" "aurelia-cli" "-g"
npm ERR! node v4.2.6
npm ERR! npm v4.0.3
npm ERR! path /usr/local/lib/node_modules/.staging/abbrev-d3948789
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall rename
npm ERR! enoent ENOENT: no such file or directory, rename '/usr/local/lib/node_modules/.staging/abbrev-d3948789' -> '/usr/local/lib/node_modules/aurelia-cli/node_modules/npm/node_modules/abbrev'
npm ERR! enoent ENOENT: no such file or directory, rename '/usr/local/lib/node_modules/.staging/abbrev-d3948789' -> '/usr/local/lib/node_modules/aurelia-cli/node_modules/npm/node_modules/abbrev'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! /etc/apt/npm-debug.log
I have no idea about that specific error, however, this often works for me, and this method of doing a fresh reinstall is often recommended on gitter by the aurelia folks:
npm uninstall -g aurelia-cli
npm clear cache
npm install -g aurelia-cli
rm -rf node_modules
npm install
npm install # on freebsd sometimes I have to run this more than once

installing npm with gitlab and ssh give ENOENT errors although the file exists

I have been having an issue on Windows 7. I have been using the following npm command to install a package from a git-labs repository.
npm install --save git+ssh://git#156.67.38.79:mma/node-typescript-bundle.git
The error I get is as follows.
It fails with the following.
$ npm install --save git+ssh://git#156.67.38.79:mma/node-typescript- bundle.git
npm ERR! addLocal Could not install C:\Users\Operator\AppData\Local\Temp\npm-7556-2bcb63a8\git-cache-ff531437\b3f389becc07c9c83e86c17919f3e869f098f123
npm ERR! Windows_NT 6.1.7601
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "--save" "git+ssh://git#156.67.38.79:mma/node-typescript-bundle.git"
npm ERR! node v6.4.0
npm ERR! npm v3.10.3
npm ERR! path C:\Users\Operator\Dev\npm-ccache\node-typescript -bundle\1.0.0\package.tgz
npm ERR! code ENOENT
npm ERR! errno -4058
npm ERR! syscall scandir
npm ERR! enoent ENOENT: no such file or directory, scandir 'C:\Users\Operator\Dev\npm-ccache\node-typescript-bundle\1.0.0\package.tgz'
npm ERR! enoent ENOENT: no such file or directory, scandir'C:\Users\Operator\Dev\npm-ccache\node-typescript-bundle\1.0.0\package.tgz'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! C:\Users\Operator\Desktop\npm-debug.log
I have taken the following steps.
Updated npm and node
Recreated the folders
npm cache clean
using the command prompt as administrator.
Searching for similar issues on google and stack overflow.
I am not sure what the issue is and any help would be appreciated. Usual npm install commands work perfectly fine.

ionic installation issue windows

Hello im trying to install ionic on my windows computer, i already installed nodejs and cordova but i m having this problem when i use the command npm install -g ionic
C:\Windows\system32>npm install -g ionic
npm ERR! addLocal Could not install C:\Windows\system32\-g
npm ERR! Windows_NT 6.3.9600
npm ERR! argv "C:\\nodejs\\node.exe"
"C:\\Users\\Alejandro\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "ionic"
npm ERR! node v4.2.3
npm ERR! npm v3.5.1
npm ERR! path C:\Windows\system32\-g
npm ERR! code ENOENT
npm ERR! errno -4058
npm ERR! syscall open
npm ERR! enoent ENOENT: no such file or directory, open 'C:\Windows\system32\-g'
npm ERR! enoent ENOENT: no such file or directory, open 'C:\Windows\system32\-g'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! C:\Windows\system32\npm-debug.log
C:\Windows\system32>

NPM error when trying to install gulp and bower

I'm trying to install gulp and bower by running npm install --global gulp bower . Everything seems to be going fine then I get this:
npm ERR! Darwin 15.0.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "--global" "yo" "gulp" "bower"
npm ERR! node v4.2.2
npm ERR! npm v3.5.0
npm ERR! path /usr/local/lib/node_modules/gulp/node_modules/vinyl-fs/node_modules/glob-stream/node_modules/ordered-read-streams
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall rename
npm ERR! enoent ENOENT: no such file or directory, rename '/usr/local/lib/node_modules/gulp/node_modules/vinyl-fs/node_modules/glob-stream/node_modules/ordered-read-streams' -> '/usr/local/lib/node_modules/gulp/node_modules/ordered-read-streams'
npm ERR! enoent ENOENT: no such file or directory, rename '/usr/local/lib/node_modules/gulp/node_modules/vinyl-fs/node_modules/glob-stream/node_modules/ordered-read-streams' -> '/usr/local/lib/node_modules/gulp/node_modules/ordered-read-streams'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! /Users/deang/npm-debug.log
I've also tried running the command using sudo, but to no avail. Any pointers?
Update:
This seems to be happening for everything I'm trying to install. Just tried sudo npm install --global generator-gulp-webapp and it did the same thing.
are you using npm 3.x? if so, try downgrading to npm 2.x (you can npm install npm#2.14.12).
npm 3.x has a couple of issues with yeoman

npm ERR! addLocal could not install in windows

Just started a new job and have to run node on windows (where all my coworkers are using OSX, which runs fine checking it out fresh)
When npm, I kept getting addLocal could not install, where it seems like it is trying to access temp directory in %APPDATA% (which does not any special permission) Where my coworker using same version of node and npm (but in mac) would not see any of these.
I have also tried downgrade node to 10.35, but I am getting another problem. Does anyone has any idea what might be the case?
Here is the stdout:
C:\Users\litehsu\workspace\myworkspace>npm install
npm WARN package.json Dependency 'grunt-sonar-runner' exists in both dependencies and devDependencies, using 'grunt-sonar-runner#2.4.3' from dependencies
npm ERR! addLocal Could not install C:\Users\litehsu\AppData\Local\Temp\npm-5440-6f1004b8\git-cache-ecdc41ed33a0\2fd99696c3f2705dcd6813454b50ad5591651427
npm ERR! addLocal Could not install C:\Users\502438~1\AppData\Local\Temp\npm-5440-6f1004b8\git-cache-87d2760d189d\e52092778d61d32bb10e3aa062bbbfaf583d2107
npm ERR! Windows_NT 6.1.7601
npm ERR! argv "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! node v0.12.4
npm ERR! npm v2.10.1
npm ERR! path C:\Users\502438914\AppData\Roaming\npm-cache\karma-support\1.0.2\package.tgz
npm ERR! code ENOENT
npm ERR! errno -4058
npm ERR! enoent ENOENT, scandir 'C:\Users\litehsu\AppData\Roaming\npm-cache\karma-support\1.0.2\package.tgz'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! C:\Users\litehsu\workspace\npm-debug.log
thank you!
Use the config to change the locations:
Run npm config ls -l
Check the path to the cache and the temp
Change them both to a new path. For example:
npm config set cache %USERPROFILE%\npm-cache
npm config set tmp %USERPROFILE%\tmp
will put them in your profile folder.
Make the same edit in all .npmrc file locations:
%appdata%\npm\node_modules\npm\.npmrc
%ProgramFiles%\nodejs\node_modules\npm\.npmrc
%USERPROFILE%\.npmrc
References
Troubleshooting NPM

Resources