This commit is contained in:
Miguel Palhas
2025-12-16 19:35:45 +00:00
parent 81b23aac35
commit 6313519050
4 changed files with 61 additions and 34 deletions
+46 -4
View File
@@ -1,10 +1,52 @@
return {
-- file managing , picker etc
{
"nvim-tree/nvim-tree.lua",
cmd = { "NvimTreeToggle", "NvimTreeFocus" },
opts = function()
return require "configs.nvimtree"
enabled = false,
},
{
"echasnovski/mini.files",
version = false,
lazy = false,
config = function()
require("mini.files").setup {
mappings = {
close = "q",
go_in = "l",
go_in_plus = "<CR>",
go_out = "h",
go_out_plus = "H",
reset = "<BS>",
reveal_cwd = "@",
show_help = "g?",
synchronize = "=",
trim_left = "<",
trim_right = ">",
},
windows = {
preview = true,
width_focus = 30,
width_nofocus = 15,
width_preview = 50,
},
options = {
use_as_default_explorer = true,
},
}
local map = vim.keymap.set
map("n", "<leader>e", function()
local MiniFiles = require "mini.files"
if not MiniFiles.close() then
MiniFiles.open(vim.api.nvim_buf_get_name(0))
end
end, { desc = "File explorer (current file)" })
map("n", "<leader>E", function()
local MiniFiles = require "mini.files"
if not MiniFiles.close() then
MiniFiles.open(vim.uv.cwd())
end
end, { desc = "File explorer (cwd)" })
end,
},
}