I want to install angular/cli from a local package, I have downloaded the package folder with package.json and all the rest of the files:
bin
commands
CONTRIBUTING.md
ember-cli
lib
LICENSE
models
node_modules
package.json
plugins
README.md
tasks
upgrade
utilities
I have tried npm install 'path/to/package' and the error log :
6041 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "C:\\Users\\t207322\\AppData\\Roaming\\npm-cache\\#angular\\cli\\1.4.4\\package"
6042 verbose node v9.3.0
6043 verbose npm v5.5.1
6044 error path C:\Users\t207322\node_modules\cryptiles\node_modules
6045 error code EPERM
6046 error errno -4048
6047 error syscall scandir
6048 error Error: EPERM: operation not permitted, scandir 'C:\Users\t207322\node_modules\cryptiles\node_modules'
6048 error { Error: EPERM: operation not permitted, scandir 'C:\Users\t207322\node_modules\cryptiles\node_modules'
6048 error stack: 'Error: EPERM: operation not permitted, scandir \'C:\\Users\\t207322\\node_modules\\cryptiles\\node_modules\'',
6048 error errno: -4048,
6048 error code: 'EPERM',
6048 error syscall: 'scandir',
6048 error path: 'C:\\Users\\t207322\\node_modules\\cryptiles\\node_modules' }
6049 error Please try running this command again as root/Administrator.
6050 verbose exit [ -4048, true ]
I had also tried inserting the package to 'AppData\Roaming\npm-cache' and running npm link with same result :
2017 verbose argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "link"
2018 verbose node v9.3.0
2019 verbose npm v5.5.1
2020 error path C:\Users\t207322\AppData\Roaming\npm-cache\#angular\cli\1.4.4\package\node_modules\scss-tokenizer\node_modules
2021 error code EPERM
2022 error errno -4048
2023 error syscall scandir
2024 error Error: EPERM: operation not permitted, scandir 'C:\Users\t207322\AppData\Roaming\npm-cache\#angular\cli\1.4.4\package\node_modules\scss-tokenizer\node_modules'
2024 error { Error: EPERM: operation not permitted, scandir 'C:\Users\t207322\AppData\Roaming\npm-cache\#angular\cli\1.4.4\package\node_modules\scss-tokenizer\node_modules'
2024 error stack: 'Error: EPERM: operation not permitted, scandir \'C:\\Users\\t207322\\AppData\\Roaming\\npm-cache\\#angular\\cli\\1.4.4\\package\\node_modules\\scss-tokenizer\\node_modules\'',
2024 error errno: -4048,
2024 error code: 'EPERM',
2024 error syscall: 'scandir',
2024 error path: 'C:\\Users\\t207322\\AppData\\Roaming\\npm-cache\\#angular\\cli\\1.4.4\\package\\node_modules\\scss-tokenizer\\node_modules' }
2025 error Please try running this command again as root/Administrator.
2026 verbose exit [ -4048, true ]
So, is there another way to install a angular/cli using a local package?
Related
I am installing Yeoman on my machine and ran this
npm install -g yo
This is giving me permission error:
npm ERR! code EACCES
npm ERR! syscall access
npm ERR! path /usr/local/nvm/versions/node/v12.16.1/lib/node_modules/yo
npm ERR! errno -13
npm ERR! Error: EACCES: permission denied, access '/usr/local/nvm/versions/node/v12.16.1/lib/node_modules/yo'
npm ERR! [Error: EACCES: permission denied, access '/usr/local/nvm/versions/node/v12.16.1/lib/node_modules/yo'] {
npm ERR! stack: "Error: EACCES: permission denied, access '/usr/local/nvm/versions/node/v12.16.1/lib/node_modules/yo'",
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'access',
npm ERR! path: '/usr/local/nvm/versions/node/v12.16.1/lib/node_modules/yo'
npm ERR! }
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/siddharth/.npm/_logs/2020-04-24T22_31_29_025Z-debug.log
But this got resolved by attaching sudo
Now I am getting this error:
Yeoman Doctor
Running sanity checks on your system
✔ No .bowerrc file in home directory
✔ Global configuration file is valid
✔ NODE_PATH matches the npm root
✔ No .yo-rc.json file in home directory
✔ Node.js version
✔ npm version
Error: Couldn't find the 'yo' binary. Make sure it's installed and in your $PATH
at Process.ChildProcess._handle.onexit (internal/child_process.js:267:19)
at onErrorNT (internal/child_process.js:469:16)
at processTicksAndRejections (internal/process/task_queues.js:84:21) {
errno: 'ENOENT',
code: 'ENOENT',
syscall: 'spawn yo',
path: 'yo',
spawnargs: [ '--version' ],
cmd: 'yo --version'
}
✖ yo version
Error: Couldn't find the 'yo' binary. Make sure it's installed and in your $PATH
at Process.ChildProcess._handle.onexit (internal/child_process.js:267:19)
at onErrorNT (internal/child_process.js:469:16)
at processTicksAndRejections (internal/process/task_queues.js:84:21) {
errno: 'ENOENT',
code: 'ENOENT',
syscall: 'spawn yo',
path: 'yo',
spawnargs: [ '--version' ],
cmd: 'yo --version'
}
Found potential issues on your machine :(
+ yo#3.1.1
updated 1 package in 29.492s
Running yo --version is giving zsh: command not found: yo
I tried this https://stackoverflow.com/a/58277450/10309895 but this is also not working for me
:,(
I git clone a Node app.
Then I try to install all the dependencies with npm install.
I get the following error.
npm ERR! code EIO
npm ERR! syscall read
npm ERR! errno -5
npm ERR! EIO: i/o error, read
npm ERR! A complete log of this run can be found in:
npm ERR! /home/foobar/.npm/_logs/2020-02-22T12_14_17_084Z-debug.log
The last lines of the log file look like this:
...
...
3830 silly saveTree └── typescript#3.8.2
3831 verbose stack Error: EIO: i/o error, read
3832 verbose cwd /home/foobar/myapp
3833 verbose Linux 5.4.18-1-MANJARO
3834 verbose argv "/usr/bin/node" "/usr/bin/npm" "install"
3835 verbose node v13.7.0
3836 verbose npm v6.13.6
3837 error code EIO
3838 error syscall read
3839 error errno -5
3840 error EIO: i/o error, read
3841 verbose exit [ -5, true ]
When I prepend the command with sudo it installs.
How can I fix this error so I don't need to run npm install with sudo?
I fixed it by deleting my ~/.npm and other node related directories in $HOME.
sharp#0.18.4 install C:\Users\hp\AppData\Roaming\npm\node_modules\sharp
node-gyp rebuild
C:\Users\hp\AppData\Roaming\npm\node_modules\sharp>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "" rebuild )
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
MSBUILD : error MSB4132: The tools version "2.0" is unrecognized. Available tools versions are "4.0".
gyp ERR! build error
gyp ERR! stack Error: `C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\build.js:258:23)
gyp ERR! stack at emitTwo (events.js:126:13)
gyp ERR! stack at ChildProcess.emit (events.js:214:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12)
gyp ERR! System Windows_NT 10.0.10240
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\Users\hp\AppData\Roaming\npm\node_modules\sharp
gyp ERR! node -v v8.9.3
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
npm WARN Error: EPERM: operation not permitted, rmdir 'C:\Users\hp\AppData\Roaming\npm\node_modules'
npm WARN { Error: EPERM: operation not permitted, rmdir 'C:\Users\hp\AppData\Roaming\npm\node_modules'
npm WARN stack: 'Error: EPERM: operation not permitted, rmdir \'C:\\Users\\hp\\AppData\\Roaming\\npm\\node_modules\'',
npm WARN errno: -4048,
npm WARN code: 'EPERM',
npm WARN syscall: 'rmdir',
npm WARN path: 'C:\\Users\\hp\\AppData\\Roaming\\npm\\node_modules' }
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! sharp#0.18.4 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the sharp#0.18.4 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\hp\AppData\Roaming\npm-cache\_logs\2017-12-27T19_25_54_261Z-debug.log
the easiest way to install sharp on windows OS is to use the following npm package
which is called windows-build-tools
npm install --global --production windows-build-tools
this as npm says it downloads
installs Visual C++ Build Tools, provided free of charge by Microsoft. These tools are required to compile popular native modules. It will also install Python 2.7, configuring your machine and npm appropriately.
after this npm install sharp
Getting this every time I try to install mean.io application have tried
npm cache clean,
tried total reinstall ,
going mad at the moment . Am also running this as administrator. pleas help
C:\Users\mmcelhinney\pitch_v1>npm install
-
> phantomjs#1.9.18 install C:\Users\mmcelhinney\pitch_v1\node_modules\phantomjs
> node install.js
Download already available at C:\Users\MMCELH~1\AppData\Local\Temp\phantomjs\phantomjs-1.9.8-windows.zip
Extracting zip contents
Removing C:\Users\mmcelhinney\pitch_v1\node_modules\phantomjs\lib\phantom
Copying extracted folder C:\Users\MMCELH~1\AppData\Local\Temp\phantomjs\phantomjs-1.9.8-windows.zip-extract-1456238458670\phantomjs-1.9.8-windows -> C:\Users\mmcelhinney\pitch_v1\node_modules\phantom
s\lib\phantom
Phantom installation failed { [Error: EPERM, unlink 'C:\Users\MMCELH~1\AppData\Local\Temp\phantomjs\phantomjs-1.9.8-windows.zip-extract-1456238458670\phantomjs-1.9.8-windows\phantomjs.exe']
errno: -4048,
code: 'EPERM',
path: 'C:\\Users\\MMCELH~1\\AppData\\Local\\Temp\\phantomjs\\phantomjs-1.9.8-windows.zip-extract-1456238458670\\phantomjs-1.9.8-windows\\phantomjs.exe' } Error: EPERM, unlink 'C:\Users\MMCELH~1\App
ata\Local\Temp\phantomjs\phantomjs-1.9.8-windows.zip-extract-1456238458670\phantomjs-1.9.8-windows\phantomjs.exe'
at Error (native)
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.0
npm ERR! npm v2.5.1
npm ERR! code ELIFECYCLE
npm ERR! phantomjs#1.9.18 install: `node install.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the phantomjs#1.9.18 install script 'node install.js'.
npm ERR! This is most likely a problem with the phantomjs package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! node install.js
npm ERR! You can get their info via:
npm ERR! npm owner ls phantomjs
npm ERR! There is likely additional logging output above.
npm ERR! error rolling back Error: EPERM, unlink 'C:\Users\mmcelhinney\pitch_v1\node_modules\phantomjs\lib\phantom\phantomjs.exe'
npm ERR! error rolling back at Error (native)
npm ERR! error rolling back { [Error: EPERM, unlink 'C:\Users\mmcelhinney\pitch_v1\node_modules\phantomjs\lib\phantom\phantomjs.exe']
npm ERR! error rolling back errno: -4048,
npm ERR! error rolling back code: 'EPERM',
npm ERR! error rolling back path: 'C:\\Users\\mmcelhinney\\pitch_v1\\node_modules\\phantomjs\\lib\\phantom\\phantomjs.exe' }
Excerpt from Debug log as well :
6379 info phantomjs#1.9.18 Failed to exec install script
6380 verbose unlock done using C:\Users\mmcelhinney\AppData\Roaming\npm-cache_locks\phantomjs-69c2bf63828d859c.lock for C:\Users\mmcelhinney\pitch_v1\node_modules\phantomjs
6381 verbose stack Error: phantomjs#1.9.18 install: node install.js
6381 verbose stack Exit status 1
6381 verbose stack at EventEmitter. (C:\Program Files\nodejs\node_modules\npm\lib\utils\lifecycle.js:213:16)
6381 verbose stack at EventEmitter.emit (events.js:110:17)
6381 verbose stack at ChildProcess. (C:\Program Files\nodejs\node_modules\npm\lib\utils\spawn.js:14:12)
6381 verbose stack at ChildProcess.emit (events.js:110:17)
6381 verbose stack at maybeClose (child_process.js:1008:16)
6381 verbose stack at Process.ChildProcess._handle.onexit (child_process.js:1080:5)
Try my solution here https://stackoverflow.com/a/35043377/5734480
It may be slightly different depending on your OS.
I'm trying to install Johnny Five using npm but I keep getting errors.
This is what I get in the Terminal window.
gyp ERR! build error
gyp ERR! stack Error: not found: make
gyp ERR! stack at F (/usr/local/lib/node_modules/npm/node_modules/which/which.js:43:28)
gyp ERR! stack at E (/usr/local/lib/node_modules/npm/node_modules/which/which.js:46:29)
gyp ERR! stack at /usr/local/lib/node_modules/npm/node_modules/which/which.js:57:16
gyp ERR! stack at Object.oncomplete (fs.js:107:15)
gyp ERR! System Darwin 12.4.0
gyp ERR! command "node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/nevosegal/GitHub/node_modules/firmata/node_modules/serialport
gyp ERR! node -v v0.10.10
gyp ERR! node-gyp -v v0.9.6
gyp ERR! not ok
npm ERR! weird error 1
npm ERR! not ok code 0
Below is the log file. Anyone?
2793 error Error: ENOENT, lstat '/Users/nevosegal/GitHub/node_modules/johnny-five/node_modules/socket.io/node_modules/socket.io-client/node_modules/uglify-js/tmp/app.js'
2794 error If you need help, you may report this log at:
2794 error <http://github.com/isaacs/npm/issues>
2794 error or email it to:
2794 error <npm-#googlegroups.com>
2795 error System Darwin 12.4.0
2796 error command "node" "/usr/local/bin/npm" "install" "johnny-five"
2797 error cwd /Users/nevosegal/GitHub
2798 error node -v v0.10.10
2799 error npm -v 1.2.25
2800 error path /Users/nevosegal/GitHub/node_modules/johnny-five/node_modules/socket.io/node_modules/socket.io-client/node_modules/uglify-js/tmp/app.js
2801 error fstream_path /Users/nevosegal/GitHub/node_modules/johnny- five/node_modules/socket.io/node_modules/socket.io-client/node_modules/uglify-js/tmp/app.js
2802 error fstream_type File
2803 error fstream_class FileWriter
2804 error code ENOENT
2805 error errno 34
2806 error fstream_stack /usr/local/lib/node_modules/npm/node_modules/fstream/lib/writer.js:284:26
2806 error fstream_stack Object.oncomplete (fs.js:107:15)
2807 verbose exit [ 34, true ]
Thanks
I'm guessing that you're on Mac. You need the program make. Install XCode from the app store, and then install the package that contains make.
Where can I find "make" program for Mac OS X Lion?