Skip to content

Commit 11131ea

Browse files
committed
feat(cmd): added Lazy load all to load all plugins
1 parent 53e1c49 commit 11131ea

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

lua/lazy/view/commands.lua

+6
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,9 @@ function M.complete(cmd, prefix)
6969
end
7070
---@type string[]
7171
local plugins = {}
72+
if cmd == "load" then
73+
plugins[#plugins + 1] = "all"
74+
end
7275
for name, plugin in pairs(Config.plugins) do
7376
if cmd ~= "load" or not plugin._.loaded then
7477
plugins[#plugins + 1] = name
@@ -86,6 +89,9 @@ function M.setup()
8689
---@type ManagerOpts
8790
local opts = { wait = cmd.bang == true }
8891
local prefix, args = M.parse(cmd.args)
92+
if #args == 1 and args[1] == "all" then
93+
args = vim.tbl_keys(Config.plugins)
94+
end
8995
if #args > 0 then
9096
---@param plugin string
9197
opts.plugins = vim.tbl_map(function(plugin)

0 commit comments

Comments
 (0)