Skip to content

[RRFC] Add semver filter to the outdated command #359

@lomby92

Description

@lomby92

Motivation ("The Why")

I was managing a repository and wanted to see if there were any new major releases in the dependencies. I was interested only to major releases changes but the npm outdated command showed to me also minor and patch changes.

Example

Allow to show only some specific type of semver changes, eg: only major and minor.

How

Current Behaviour

The npm outdated command shows all dependencies with an update

Desired Behaviour

Allow to specify a filter parameter like --include-versions that takes as input a string or a list of comma-separated strings.

Example:

npm outdated

Package      Current          Wanted        Latest
dep1         1.0.1            1.0.1         1.1.0
dep2         3.2.122          3.2.122       4.0.0
dep1         0.0.1            0.0.1         0.0.2


npm outdated --include-versions major,minor

Package      Current          Wanted        Latest
dep1         1.0.1            1.0.1         1.1.0
dep2         3.2.122          3.2.122       4.0.0

References

  • n/a

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions