Can't seem to win installing gulp globally on my Windows 10 machine - gulp

I keep getting this message when trying to install gulp globally, i have tried a lot of the solutions and nothing seem to work for me.
$ npm install --global gulp-cli
npm WARN deprecated resolve-url#0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated urix#0.1.0: Please see https://github.com/lydell/urix#deprecated
C:\Users\Jerry\AppData\Roaming\npm\gulp -> C:\Users\Jerry\AppData\Roaming\npm\node_modules\gulp-cli\bin\gulp.js
gulp-cli#2.3.0
added 235 packages from 163 contributors and updated 1 package in 40.499s

Related

npm ERR! Unexpected end of JSON input while parsing near '...#types/run-sequence":

npm ERR! Unexpected end of JSON input while parsing near '...#types/run-sequence":'
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Acer\AppData\Roaming\npm-cache_logs\2020-05-24T09_59_48_560Z-debug.log
× Package install failed, see above.
The Schematic workflow failed. See above.
When I create a new angular project using "ng new newApp", Above error occured. I tried so many solutions, but did not work.
I just uninstalled angular using the command,
npm uninstall -g #angular/cli
Then I cleared the cache using the following command,
npm cache clean --force
Then I reinstalled angular,
npm install -g #angular/cli
Then it worked successfully.

Getting errors on creating new project using command 'ng new <project_name>' after upgrading to version 9

Please find the stack over here...
Installing packages...npm WARN deprecated tslint#6.1.2: TSLint has been deprecated in favor of ESLint. Please see https://github.com/palantir/tslint/issues/4534 for more information.
npm WARN deprecated request#2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated chokidar#2.1.8: Chokidar 2 will break on node v14+. Upgrade to chokidar 3 with 15x less dependencies.
npm WARN deprecated fsevents#1.2.12: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
npm WARN deprecated urix#0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated resolve-url#0.2.1: https://github.com/lydell/resolve-url#deprecated
npm ERR! Unexpected end of JSON input while parsing near '...iERRHPyU8nBqZB1+iv2Uh'
I had the exact same error and was able to fix it through following steps.
Run npm cache clean --force
Manually delete npm and npm-cache folders from AppData/Roaming folder (Win + R, Type %AppData% and enter)
Run Node Installer and repair
Reinstall npm install -g #angular/cli
Rerun ng new newApp
Worked :)
Use node V12.4.0 and npm V6.9.0
i was getting the same issue please try reinstall angular CLI after installing previous one
I think this can only be achieved if we first update the version to 8 and then move from 8 to 9.
I had the same Issue and Following steps worked for me.
Delete npm-cache in AppData/Roaming
Reinstall the angular cli by 'npm install -g #angular/cli'
Then Create the project
Run npm cache clean --force
Manually delete npm and npm-cache folders from AppData/Roaming folder (Win + R, Type %AppData% and enter)
Run Node Installer and repair
4.Reinstall npm install -g #angular/cli
Rerun ng new newApp
Worked :)
https://github.com/npm/cli/issues/1191
Delete the AppData\Roaming\npm-cache folder and then try creating the project again. This is really gonna work =)

#polymer/lit-element has been deprecated

I am using #polymer/lit-element for my application.Recently I did npm install
which led to following error
"npm WARN deprecated #polymer/lit-element#0.5.2: #polymer/lit-element has moved to lit-element. Please uninstall this package and install lit-element. See https://www.polymer-project.org/blog/2019-01-11-lit-element-rc".
When I checked my node_modules, the lit-element folder had been deleted from #polymer folder.Is there any way that I can get back my #polymer/lit-element?
( Apart from the point that I have to migrate whole my application to lit-element which sounds tedious )
npm WARN deprecated #polymer/lit-element#0.5.2 is a warning not an error. v0.5.2 is still available for use. You can npm install to install the dependencies listed in your package.json or if #polymer/lit-element is not listed in in package.json you can add it with npm install --save #polymer/lit-element#0.5.1.
That being said #polymer/lit-element is deprecated and being replaced with lit-element. You should replace #polymer/lit-element with lit-element within package.json and your codebase.

Why getting error when installing gulp-sass on app directory?

I have installed global instance of gulp and worked fine:
npm install -g gulp
npm install -g gulp-sass
But when I try to install in the app directory
npm install gulp-sass
I´m getting several errors, starting with
gyp WARN install got an error, rolling back install
gyp ERR! configure error
gyp ERR! stack Error: 404 status code downloading 32-bit node.lib
I've tried to uninstall and install GULP again, also rebuild command. Still I got no luck.
Any idea what it would be?
Thanks
Please check the version of the dependency in the file package.json.
I am using gulp-sass 2.0.4 and the installation went fine.
"gulp-sass": "^2.0.4",

MySQL driver for NodeDB: db-mysql gives node waf error on Mountain Lion

So I am just starting out with node and npm on Mountain Lion, and have been following the Node Up and Running book to work with databases (http://chimera.labs.oreilly.com/books/1234000001808/ch06.html#mysql).
When I tried sudo npm install -g db-mysql I get this message:
npm ERR! db-mysql#0.7.6 install: `node-waf configure build`
npm ERR! Exit status 127
npm ERR!
npm ERR! Failed at the db-mysql#0.7.6 install script.
npm ERR! This is most likely a problem with the db-mysql package,
npm ERR! not with npm itself.
I've tried seeing if others have run into this. Most of the answers I've found have been focused on other installs (During npm install socket.io I get error 127, node-waf command not found. How to solve it?), directed to Ubuntu (or Windows) users or simply advocate installing the mysql driver (How to install nodejs modules on windows7?).
The closest I've gotten is this solution in the project's issue thread, to just clone the source and replace node-waf with node-gyp: https://github.com/mariano/node-db-mysql/issues/98. However the thread was started for ArchLinux, and a user ran into an error on Mountain Lion at the last step of the solution.
Is there a significant difference between the db-mysql and mysql drivers in practice? Are these the only options? If there is a reason to use db-mysql, how can I solve this install issue on Mountain Lion?
I am choosing node-mysql as the driver instead, I've found:
It's up to date, easier to install (https://github.com/felixge/node-mysql)
It works with the latest version MySQL cluster too, although MySQL cluter v7.3.1 and below use node-waf rather than node-gyp (https://dev.mysql.com/doc/ndbapi/en/ndb-nodejs-setup.html)
It supports collection pooling (node-mysql connection pooling)