added file explorer, auto open when reading a file
This commit is contained in:
parent
7a44cf22f8
commit
03f77fc616
8
init.lua
8
init.lua
|
|
@ -247,6 +247,14 @@ require('lazy').setup({
|
||||||
--
|
--
|
||||||
-- Use `opts = {}` to automatically pass options to a plugin's `setup()` function, forcing the plugin to be loaded.
|
-- Use `opts = {}` to automatically pass options to a plugin's `setup()` function, forcing the plugin to be loaded.
|
||||||
--
|
--
|
||||||
|
-- This is equivalent to:
|
||||||
|
-- require('Comment').setup({})
|
||||||
|
|
||||||
|
-- "gc" to comment visual regions/lines
|
||||||
|
{ 'numToStr/Comment.nvim', opts = {} },
|
||||||
|
{ 'vidocqh/data-viewer.nvim', opts = {}, dependencies = {
|
||||||
|
'nvim-lua/plenary.nvim',
|
||||||
|
} },
|
||||||
|
|
||||||
-- Alternatively, use `config = function() ... end` for full control over the configuration.
|
-- Alternatively, use `config = function() ... end` for full control over the configuration.
|
||||||
-- If you prefer to call `setup` explicitly, use:
|
-- If you prefer to call `setup` explicitly, use:
|
||||||
|
|
|
||||||
|
|
@ -7,4 +7,23 @@ return {
|
||||||
'tanvirtin/monokai.nvim',
|
'tanvirtin/monokai.nvim',
|
||||||
'folke/tokyonight.nvim',
|
'folke/tokyonight.nvim',
|
||||||
'EdenEast/nightfox.nvim',
|
'EdenEast/nightfox.nvim',
|
||||||
|
{
|
||||||
|
'nvim-tree/nvim-tree.lua',
|
||||||
|
config = function()
|
||||||
|
vim.g.loaded_netrw = 1
|
||||||
|
vim.g.loaded_netrwPlugin = 1
|
||||||
|
vim.api.nvim_create_autocmd('BufReadPost', {
|
||||||
|
callback = function(data)
|
||||||
|
local api = require 'nvim-tree.api'
|
||||||
|
api.tree.open()
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
require('nvim-tree').setup {
|
||||||
|
sort = { sorter = 'case_sensitive' },
|
||||||
|
view = { width = 30 },
|
||||||
|
renderer = { group_empty = true },
|
||||||
|
filters = { dotfiles = true },
|
||||||
|
}
|
||||||
|
end,
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue