Skip to Content
2
Jul 12, 2020 at 09:42 AM

Why cds init insert line package-lock.json in .gitignore?

169 Views Last edit Jul 12, 2020 at 09:57 AM 2 rev

Hi,

The best practice seems to be to commit the file "package-lock.json" into the source repository, looking at:

https://docs.npmjs.com/files/package-lock.json

but the command "cds init" insert the line "package-lock.json" into .gitignore, why?

Use case: I have a solution not yet published in production so no shrinkwrap yet, I removed the sap npm registry and done npm update, I wanted to check the changes to packages-lock.json but I discovered was not under versioning.

Thanks

Best Regards,

Sam

Attachments

l9dlj.png (8.0 kB)