'Why is Npm modifying package-lock.json?

I’ve got the lock file under Git. After performing several Npm commands, the lock file gets modified - a bunch of new packages get added to it. The commands are:

  • npm config -g set ...
  • npm install -g ...
  • npm run test

That’s it. No new packages are added to the project, package.json is untouched. Why would the lock file change please?

npm


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source