mirror of
https://github.com/folke/lazy.nvim.git
synced 2025-04-18 20:36:45 +00:00
fix(pkg): versioning and reload specs when pkg-cache is dirty
This commit is contained in:
parent
183f59e2e8
commit
fd8229d6e3
5 changed files with 59 additions and 48 deletions
|
@ -1,5 +1,6 @@
|
|||
local Config = require("lazy.core.config")
|
||||
local Meta = require("lazy.core.meta")
|
||||
local Pkg = require("lazy.pkg")
|
||||
local Util = require("lazy.core.util")
|
||||
|
||||
---@class LazyCorePlugin
|
||||
|
@ -332,6 +333,12 @@ function M.load()
|
|||
Util.track("state")
|
||||
M.update_state()
|
||||
Util.track()
|
||||
|
||||
if Config.options.pkg.enabled and Pkg.dirty then
|
||||
Pkg.update()
|
||||
return M.load()
|
||||
end
|
||||
|
||||
M.loading = false
|
||||
vim.api.nvim_exec_autocmds("User", { pattern = "LazyPlugins", modeline = false })
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue