cli
cli copied to clipboard
[BUG] npm i in macOS and Windows produces different package-lock
Is there an existing issue for this?
- [X] I have searched the existing issues
This issue exists in the latest npm version
- [X] I am using the latest npm
Current Behavior
We have developers using Windows and macOS and we've noticed for local packages installed in Windows it uses forward slashes, while on macOS it uses backward slash. This becomes an issue since we are getting a "change" which isn't really a significant change.

Expected Behavior
Should use same kind of slash
Steps To Reproduce
- npm install local package in Windows
- npm install local package in macOS
Environment
- npm: 8.19.4
- Node.js: 16.20.0
- OS Name: macOS
Few years later, I ran into the same issue. It helped adding the backslashes in my package.json, looks like unix systems are able to handle that.
I have the same problem. Can this lead to installation errors on other OSes?