npm-check-updatesnode >= 10.17 (using 12.18.0)package.json an entry like this:"pkgname": "git+https://abc123:[email protected]/organization/reponame.git#v0.4.2"
npm install -g [email protected]ncu --semverLevel majorCrashes with an error, and doesn't output anything for non-git paths.
Error: Command failed: git ls-remote --tags git+https://github.com/organization/reponame.git
git: 'remote-git+https' is not a git command. See 'git --help'.
at ChildProcess.exithandler (child_process.js:303:12)
at ChildProcess.emit (events.js:315:20)
at maybeClose (internal/child_process.js:1021:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5) {
killed: false,
code: 128,
signal: null,
cmd: 'git ls-remote --tags git+https://github.com/organization/reponame.git',
stdout: '',
stderr: "git: 'remote-git+https' is not a git command. See 'git --help'.\n"
}
Should gracefully skip the problematic dependency, ideally doing something sensible
Looks linked to #716 - maybe special case on Windows (or something else) that is not taken into account.
The same issue. I have reverted ncu to 7.x
Thanks for reporting!
Try v8.0.4
Related: #727
@raineorshine I am running v8.0.4 but I'm still getting an error when running ncu -u... because of an entry in my package.json of the form:
"dependencies": {
"common": "git+https://username:[email protected]/somename/common.git#v283",
}
Error is:
Upgrading /root/workspace/myapp/package.json
[===================-] 26/27 96%/usr/lib/node_modules/npm-check-updates/lib/npm-check-updates.js:348
throw err
^
TypeError: Invalid Version: v283
at new SemVer (/usr/lib/node_modules/npm-check-updates/node_modules/semver/classes/semver.js:41:13)
at outside (/usr/lib/node_modules/npm-check-updates/node_modules/semver/ranges/outside.js:12:13)
at Object.ltr (/usr/lib/node_modules/npm-check-updates/node_modules/semver/ranges/ltr.js:3:42)
at isUpgradeable (/usr/lib/node_modules/npm-check-updates/lib/versionmanager.js:211:17)
at /usr/lib/node_modules/npm-check-updates/lib/versionmanager.js:160:67
at /usr/lib/node_modules/npm-check-updates/node_modules/lodash/lodash.js:13616:16
at basePickBy (/usr/lib/node_modules/npm-check-updates/node_modules/lodash/lodash.js:3783:13)
at Function.pickBy (/usr/lib/node_modules/npm-check-updates/node_modules/lodash/lodash.js:13615:14)
at /usr/lib/node_modules/npm-check-updates/node_modules/lodash/lodash.js:4388:28
at arrayReduce (/usr/lib/node_modules/npm-check-updates/node_modules/lodash/lodash.js:683:21)
Never got such an error before upgrading to version 8.
Indeed you are correct! Let me look into it.
Should be fixed in 4fcfcd0.
Please try v8.0.5
A published fix within around 15 mins... very impressive! Yes, I can confirm that an error is no longer thrown. Thanks!
Confirming the bug is fixed. That was fast! 馃憣
Most helpful comment
Should be fixed in 4fcfcd0.
Please try
v8.0.5