17 lines
497 B
Lua
17 lines
497 B
Lua
return {
|
|
{
|
|
"stevearc/oil.nvim",
|
|
cmd = "Oil",
|
|
keys = { { "-", "<cmd>Oil<cr>", desc = "Open parent directory" } },
|
|
init = function()
|
|
-- Load at startup only when nvim was opened on a directory.
|
|
local arg = vim.fn.argc() == 1 and vim.fn.argv(0)
|
|
local stat = arg and vim.uv.fs_stat(arg)
|
|
if stat and stat.type == "directory" then
|
|
require("lazy").load({ plugins = { "oil.nvim" } })
|
|
end
|
|
end,
|
|
opts = { default_file_explorer = true },
|
|
},
|
|
}
|