Skip to content

docs: use the latest version for global update and outdated's wanted - #9401

Merged
owlstronaut merged 2 commits into
npm:latestfrom
liangmiQwQ:docs/use-latest-as-wanted
Jun 5, 2026
Merged

docs: use the latest version for global update and outdated's wanted#9401
owlstronaut merged 2 commits into
npm:latestfrom
liangmiQwQ:docs/use-latest-as-wanted

Conversation

@liangmiQwQ

Copy link
Copy Markdown
Contributor

For now, npm outdated's document shows wanted field for global npm outdated is always the same as current field, but the runtime behavior shows npm outdated prints wanted as latest version. Considering npm update's behavior, it should be a document issue.

This PR fixes it by saying the latest version instead of currently-installed version.

References

Close#3612

@owlstronautowlstronaut left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you also update npm-update.md in this pr? The "treated as if installed with a caret semver range" not has the same mismatch with actual behavior and contradicts the fix you're making here

@liangmiQwQliangmiQwQ changed the title docs(outdated): make wanted be latest versiondocs: show the latest version for global update or outdated's wantedJun 2, 2026
@liangmiQwQ

Copy link
Copy Markdown
ContributorAuthor

Could you also update npm-update.md in this pr? The "treated as if installed with a caret semver range" not has the same mismatch with actual behavior and contradicts the fix you're making here

I've updated in e31d9fc, and PR title is updated to fit the new scope as well. Thanks.

@liangmiQwQliangmiQwQ changed the title docs: show the latest version for global update or outdated's wanteddocs: use the latest version for global update and outdated's wantedJun 2, 2026
@owlstronaut
owlstronaut merged commit 455aa4a into npm:latestJun 5, 2026
12 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

🎉 Backport to release/v11 created: #9501

owlstronaut pushed a commit that referenced this pull request Jun 5, 2026
#9501)
Backport of #9401 to `release/v11`.
Co-authored-by: Liang <github@liangmi.dev>
@github-actionsgithub-actionsBot mentioned this pull request Jun 5, 2026
@liangmiQwQ
liangmiQwQ deleted the docs/use-latest-as-wanted branch June 5, 2026 23:14
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] npm outdated -g outputs that it wants to upgrade to a new major version

2 participants

@liangmiQwQ@owlstronaut