mirror of
https://github.com/folke/lazy.nvim.git
synced 2025-04-18 20:36:45 +00:00
feat: packspec
This commit is contained in:
parent
4ea9fe0600
commit
8eba74c3fc
6 changed files with 190 additions and 2 deletions
|
@ -179,6 +179,11 @@ M.defaults = {
|
|||
-- Track each new require in the Lazy profiling tab
|
||||
require = false,
|
||||
},
|
||||
packspec = {
|
||||
enabled = true,
|
||||
versions = true, -- Honor dependency versions in packspecs
|
||||
path = vim.fn.stdpath("state") .. "/lazy/packspec.lua",
|
||||
},
|
||||
debug = false,
|
||||
}
|
||||
|
||||
|
@ -281,6 +286,14 @@ function M.setup(opts)
|
|||
require("lazy.manage.checker").start()
|
||||
end, 10)
|
||||
end
|
||||
|
||||
-- useful for plugin developers when making changes to a packspec file
|
||||
vim.api.nvim_create_autocmd("BufWritePost", {
|
||||
pattern = "package.lua",
|
||||
callback = function()
|
||||
require("lazy.view.commands").cmd("packspec")
|
||||
end,
|
||||
})
|
||||
end,
|
||||
})
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue