Skip to content

Update dependency npm-check-updates to v16.10.0 #26

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 3, 2023

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Apr 2, 2023

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
npm-check-updates 16.9.0 -> 16.10.0 age adoption passing confidence

Release Notes

raineorshine/npm-check-updates

v16.10.0

Compare Source

Feature

  • Added filterResults option to filter out upgrades based on a user provided function.

filterResults runs after new versions are fetched, in contrast to filter and filterVersion, which run before. This allows you to filter out upgrades with filterResults based on how the version has changed (e.g. a major version change).

Only available in .ncurc.js or when importing npm-check-updates as a module.

/** Filter out non-major version updates.
  @​param {string} packageName               The name of the dependency.
  @​param {string} currentVersion            Current version declaration (may be range).
  @​param {SemVer[]} currentVersionSemver    Current version declaration in semantic versioning format (may be range).
  @​param {string} upgradedVersion           Upgraded version.
  @​param {SemVer} upgradedVersionSemver     Upgraded version in semantic versioning format.
  @​returns {boolean}                        Return true if the upgrade should be kept, otherwise it will be ignored.
*/
filterResults: (packageName, {currentVersion, currentVersionSemver, upgradedVersion, upgradedVersionSemver}) => {
  const currentMajorVersion = currentVersionSemver?.[0]?.major
  const upgradedMajorVersion = upgradedVersionSemver?.major
  if (currentMajorVersion && upgradedMajorVersion) {
    return currentMajorVersion < upgradedMajorVersion
  }
  return true
}

For the SemVer type definition, see: https://git.coolaj86.com/coolaj86/semver-utils.js#semverutils-parse-semverstring

Thanks to mslowiak for this enhancement!


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate. View repository job log here.

@codewithmmak codewithmmak merged commit 2547041 into master Apr 3, 2023
@renovate renovate bot deleted the renovate/npm-check-updates-16.x-lockfile branch April 3, 2023 09:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant