aws / aws-lambda-builders

Python library to compile, build & package AWS Lambda functions for several runtimes & framework
Apache License 2.0
333 stars 137 forks source link

fix: use npm update when building in source #579

Closed mndeveci closed 9 months ago

mndeveci commented 9 months ago

Issue #, if available: N/A

Description of changes: When --build-in-source is used, npm install command won't remove any dependency that is removed between 2 invocations.

This PR addresses that by adding NodejsNpmUpdateAction and using it when build-in-source is enabled which runs npm --no-audit --no-save --unsafe-perm --production --no-package-lock --install-links.

--install-links flag is also removed from NodejsNpmInstallAction which was only used for build in source workflow.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.