28 lines
632 B
Lua
28 lines
632 B
Lua
-- Install a file explorer
|
|
-- https://github.com/nvim-tree/nvim-tree.lua
|
|
-- nvim-tree as replacement for neo-tree
|
|
|
|
return {
|
|
"nvim-tree/nvim-tree.lua",
|
|
version = "*",
|
|
lazy = false,
|
|
dependencies = {
|
|
"nvim-tree/nvim-web-devicons",
|
|
},
|
|
config = function()
|
|
-- disable netrw at the very start of your init.lua
|
|
vim.g.loaded_netrw = 1
|
|
vim.g.loaded_netrwPlugin = 1
|
|
|
|
require("nvim-tree").setup({})
|
|
|
|
-- <leader>e to toggle the explorer buffer
|
|
vim.keymap.set(
|
|
"n",
|
|
"<leader>e",
|
|
"<cmd>NvimTreeFindFileToggle<CR>",
|
|
{ desc = "[nvim-tree] Toggle the file explorer" }
|
|
)
|
|
end,
|
|
}
|