-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
nvim-tree.lua
74 lines (59 loc) · 1.47 KB
/
nvim-tree.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
local M = {
'kyazdani42/nvim-tree.lua',
config = function(config)
require('nvim-tree').setup(config['nvim-tree'])
end,
highlights = function(config)
local c = config.colors
return { NvimTreeNormal = { bg = c.grey1 } }
end,
defaultConfig = {
'nvim-tree',
{
sort_by = 'case_sensitive',
threshold = vim.log.levels.WARN,
remove_keymaps = { 'bmv' },
view = {
width = 30,
mappings = {
list = {
{ key = '?', action = 'toggle_help' },
{ key = 'H', action = 'dir_up' },
{ key = { 'L', '<C-]>', '<2-RightMouse>' }, action = 'cd' },
{ key = 'v', action = 'vsplit' },
{ key = 's', action = 'split' },
{ key = 't', action = 'tabnew' },
{ key = 'i', action = 'toggle_dotfiles' },
{ key = 'p', action = 'parent_node' },
{ key = 'P', action = 'paste' },
},
},
float = { enable = false },
},
renderer = {
group_empty = true,
icons = {
symlink_arrow = ' ➜ ',
glyphs = {
git = {
unstaged = '',
staged = '',
unmerged = '',
renamed = '➜',
untracked = '',
deleted = '',
ignored = '◌',
},
},
},
},
filters = { dotfiles = true },
actions = { use_system_clipboard = true },
},
},
keymaps = {
{ 'n', '<leader>nm', ':NvimTreeToggle<CR>', { silent = true } },
{ 'n', '<leader>nf', ':NvimTreeFindFile<CR>', { silent = true } },
{ 'n', '<space>m', ':NvimTreeToggle<CR>' },
},
}