You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is min-release-age feature not available for npm ci? I can't see it in the documentation, and testing locally it doesn't seem to work so I am assuming it isn't. Is there any plans to add it?
npm ci installs the lockfile verbatim and doesn't perform resolution, so min-release-age has no effect. Use npm install --min-release-age=N when generating/updating the lockfile.
Thanks @owlstronaut
What if the lockfile was generated locally without min-release-age and I want to ensure in my pipeline that the cooldown period is applied when installing with npm ci?
That is currently a hole in the process. I considered adding something like that to the audit command, but it's a pretty expensive operation, particularly in CI - it means for each package in a tree, hitting the registry and seeing if it meets the requirement, and then you are hitting the registry again in the install step. I don't have a current good answer for your workflow outside of making sure what you commit is a package-lock generated with the min-release-age setup.
Activity
v-kchindam-infy commentedon Apr 24, 2026
Hi @pealtrufo please check https://docs.npmjs.com/cli/v11/using-npm/config#min-release-age
pealtrufo commentedon Apr 24, 2026
Thanks @kchindam-infy
Yes, I know it works for
npm install. It doesn't seem to be the case fornpm cithough.https://docs.npmjs.com/cli/v11/commands/npm-install#min-release-age
https://docs.npmjs.com/cli/v11/commands/npm-ci
owlstronaut commentedon Apr 28, 2026
npm ciinstalls the lockfile verbatim and doesn't perform resolution, somin-release-agehas no effect. Usenpm install --min-release-age=Nwhen generating/updating the lockfile.pealtrufo commentedon Apr 29, 2026
Thanks @owlstronaut
What if the lockfile was generated locally without
min-release-ageand I want to ensure in my pipeline that the cooldown period is applied when installing withnpm ci?owlstronaut commentedon May 4, 2026
That is currently a hole in the process. I considered adding something like that to the audit command, but it's a pretty expensive operation, particularly in CI - it means for each package in a tree, hitting the registry and seeing if it meets the requirement, and then you are hitting the registry again in the install step. I don't have a current good answer for your workflow outside of making sure what you commit is a package-lock generated with the min-release-age setup.
Add NPM minimum release age enforcement (issue #84) (#107)