kickstart.nvim/lua/kickstart/plugins/neo-tree.lua

47 lines
1.3 KiB
Lua

-- Neo-tree is a Neovim plugin to browse the file system
-- https://github.com/nvim-neo-tree/neo-tree.nvim
return {
'nvim-neo-tree/neo-tree.nvim',
version = '*',
dependencies = {
'nvim-lua/plenary.nvim',
'nvim-tree/nvim-web-devicons', -- not strictly required, but recommended
'MunifTanjim/nui.nvim',
{
's1n7ax/nvim-window-picker',
version = '2.*',
config = function()
require('window-picker').setup {
filter_rules = {
include_current_win = false,
autoselect_one = true,
-- filter using buffer options
bo = {
-- if the file type is one of following, the window will be ignored
filetype = { 'neo-tree', 'neo-tree-popup', 'notify' },
-- if the buffer type is one of following, the window will be ignored
buftype = { 'terminal', 'quickfix' },
},
},
}
end,
},
},
cmd = 'Neotree',
keys = {
{ '\\', ':Neotree reveal<CR>', desc = 'NeoTree reveal' },
},
opts = {
filesystem = {
window = {
mappings = {
['\\'] = 'close_window',
},
},
find_command = 'which', -- 這邊可能根據使用系統更換 fd / find / which
check_gitignore_in_search = false,
},
},
}