npm-check-updates
npm-check-updates copied to clipboard
Ignore global NPM modules that are symlinked to a local package
- [x] I have read the list of known issues before filing this issue.
- [x] I have searched for similiar issues before filing this issue.
- node version: v12.12.0
- npm version: 6.12.0
- npm-check-updates version: 3.1.25
I've got a few packages on my computer, which I symlink their bin via NPM global modules, by using sudo npm install -g . in the package's dir. This creates a binary that points to the project.
When running ncu -g, it looks up the symlinked module's name and sees that my version is 1.0.0 (I never bother increasing it, since it's only me using it), while a module in NPM with the same name is some version like 2.3.4. So, ncu -g tells me it's outdated.
Instead, ncu should skip checking modules that are symlinked.
I have some modules that are npm -g linked. I do not have an issue with those. Is manual symlinking standard? If not I do not think it would be wise to support it.
Ah I see. You used npm install -g ..
This feature is not currently planned due to the possibility of false positives (other symlink setups).
I recommend manually excluding local packages by adding them to the reject list in your ~/.npmrc.