Skip to content

Please add mason.status and mason.has_updates for programatic updates check #1843

@den-is

Description

@den-is

I've searched open issues for similar requests

  • Yes

Is your feature request related to a problem? Please describe.

I constantly forget to check if packages installed via Mason have updates (LSs, formatters, linters, etc).
There are no visual cues, unless I recall and manually open :Mason to check for updates.

Describe the solution you'd like

lazy.nvim has useful API to check plugins update lazy.status and functions require("lazy.status").has_updates conditional check, require("lazy.status").updates outputs number of updates.

Here you can see example of how community uses it with lualine https://github.com/den-is/nvim/blob/f2afb9b194dfaa3c196dbf8d56c6dff254a33c06/lua/plugins/lualine.lua#L19-L23

Describe potential alternatives you've considered

I'm not lua/neovim pro I've google for the similar issue and read Mason doc/src_code but did not find anything similar to solve it.

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions