mirror of
https://github.com/LunarVim/LunarVim.git
synced 2024-09-20 10:35:08 +02:00
feat(mason): add support for mason-registry (#3994)
* feat(mason): add support for mason-registry * fix(lazy)!: wrap refresh for mason-registry
This commit is contained in:
parent
b765f95508
commit
0b13c9f6bc
3 changed files with 33 additions and 3 deletions
|
@ -5,6 +5,9 @@ local join_paths = require("lvim.utils").join_paths
|
|||
function M.config()
|
||||
lvim.builtin.mason = {
|
||||
ui = {
|
||||
check_outdated_packages_on_open = true,
|
||||
width = 0.8,
|
||||
height = 0.9,
|
||||
border = "rounded",
|
||||
keymaps = {
|
||||
toggle_package_expand = "<CR>",
|
||||
|
@ -19,6 +22,12 @@ function M.config()
|
|||
},
|
||||
},
|
||||
|
||||
icons = {
|
||||
package_installed = "◍",
|
||||
package_pending = "◍",
|
||||
package_uninstalled = "◍",
|
||||
},
|
||||
|
||||
-- NOTE: should be available in $PATH
|
||||
install_root_dir = join_paths(vim.fn.stdpath "data", "mason"),
|
||||
|
||||
|
@ -26,6 +35,7 @@ function M.config()
|
|||
PATH = "skip",
|
||||
|
||||
pip = {
|
||||
upgrade_pip = false,
|
||||
-- These args will be added to `pip install` calls. Note that setting extra args might impact intended behavior
|
||||
-- and is not recommended.
|
||||
--
|
||||
|
@ -41,6 +51,21 @@ function M.config()
|
|||
-- packages that are requested to be installed will be put in a queue.
|
||||
max_concurrent_installers = 4,
|
||||
|
||||
-- [Advanced setting]
|
||||
-- The registries to source packages from. Accepts multiple entries. Should a package with the same name exist in
|
||||
-- multiple registries, the registry listed first will be used.
|
||||
registries = {
|
||||
"lua:mason-registry.index",
|
||||
"github:mason-org/mason-registry",
|
||||
},
|
||||
|
||||
-- The provider implementations to use for resolving supplementary package metadata (e.g., all available versions).
|
||||
-- Accepts multiple entries, where later entries will be used as fallback should prior providers fail.
|
||||
providers = {
|
||||
"mason.providers.registry-api",
|
||||
"mason.providers.client",
|
||||
},
|
||||
|
||||
github = {
|
||||
-- The template URL to use when downloading assets from GitHub.
|
||||
-- The placeholders are the following (in order):
|
||||
|
|
|
@ -27,6 +27,11 @@ local core_plugins = {
|
|||
require("lvim.core.mason").setup()
|
||||
end,
|
||||
cmd = { "Mason", "MasonInstall", "MasonUninstall", "MasonUninstallAll", "MasonLog" },
|
||||
build = function()
|
||||
pcall(function()
|
||||
require("mason-registry").refresh()
|
||||
end)
|
||||
end,
|
||||
lazy = true,
|
||||
},
|
||||
{
|
||||
|
|
|
@ -54,13 +54,13 @@
|
|||
"commit": "b64fded"
|
||||
},
|
||||
"mason.nvim": {
|
||||
"commit": "698b282"
|
||||
"commit": "5e059a0"
|
||||
},
|
||||
"neodev.nvim": {
|
||||
"commit": "7330427"
|
||||
},
|
||||
"nlsp-settings.nvim": {
|
||||
"commit": "1986267"
|
||||
"commit": "23705ee"
|
||||
},
|
||||
"null-ls.nvim": {
|
||||
"commit": "0180603"
|
||||
|
@ -78,7 +78,7 @@
|
|||
"commit": "bdb94e3"
|
||||
},
|
||||
"nvim-lspconfig": {
|
||||
"commit": "e99d159"
|
||||
"commit": "c345220"
|
||||
},
|
||||
"nvim-navic": {
|
||||
"commit": "59b997f"
|
||||
|
|
Loading…
Reference in a new issue