Autocommit 2023-07-25 11:07:37
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
function conf()
|
||||
--- Ensure nvim-tree is avaiable
|
||||
local function config()
|
||||
--- Ensure plugin is avaiable
|
||||
local nvimtree = require("nvim-tree")
|
||||
|
||||
--- Unload netrw
|
||||
vim.g.loaded_netrw = 1
|
||||
vim.g.loaded_netrwPlugin = 1
|
||||
|
||||
--- Nvimtree options
|
||||
--- Plugin options
|
||||
local opts = {
|
||||
sort = {
|
||||
-- sorter = "case_sensitive",
|
||||
@@ -33,15 +33,10 @@ function conf()
|
||||
},
|
||||
}
|
||||
|
||||
--- Load plugin
|
||||
nvimtree.setup(opts)
|
||||
|
||||
--- Override keymap
|
||||
local wk = require("which-key")
|
||||
wk.register({
|
||||
e = {
|
||||
name = "NvimTree", -- optional group name
|
||||
},
|
||||
}, { prefix = "<leader>" })
|
||||
local km = vim.keymap.set
|
||||
km('n', '<C-e>', ':NvimTreeFocus<cr>')
|
||||
km('n', '<leader>ee', ':NvimTreeToggle<cr>')
|
||||
@@ -57,5 +52,5 @@ return {
|
||||
dependencies = {
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
},
|
||||
config = conf
|
||||
config = config
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user