feat(lazy): allow for hot loading plugin specs

This commit is contained in:
2024-04-21 03:20:28 +02:00
parent 2e36ef05d9
commit ac1e40bfee
31 changed files with 683 additions and 831 deletions
+16 -21
View File
@@ -1,9 +1,19 @@
-- https://github.com/is0n/fm-nvim
local function setup()
local fm = require("fm-nvim")
fm.setup({
---@type LazyPluginSpec
return {
"is0n/fm-nvim",
keys = {
{
"<leader>fe",
function()
local file = vim.fn.expand("%:p")
if file ~= "" then vim.cmd.Lf(file) else vim.cmd.Lf() end
end,
mode = "n",
},
},
opts = {
-- UI Options
ui = {
float = {
@@ -16,20 +26,5 @@ local function setup()
cmds = {
nnn_cmd = "n",
},
})
vim.keymap.set(
"n",
"<leader>fe",
function()
local file = vim.fn.expand("%:p")
if file ~= "" then
vim.cmd.Lf(file)
else
vim.cmd.Lf()
end
end
)
end
return setup
},
}