mirror of
https://github.com/pojokcodeid/nvim-lazy.git
synced 2025-06-21 16:39:04 +02:00
add: update config
This commit is contained in:
parent
60b34681f6
commit
8b1ecc923b
2 changed files with 7 additions and 8 deletions
|
@ -65,9 +65,3 @@ vim.g.VM_Insert_hl = "DiffChange"
|
|||
-- end
|
||||
-- end,
|
||||
-- })
|
||||
|
||||
-- auto open file if creation
|
||||
local api = require("nvim-tree.api")
|
||||
api.events.subscribe(api.events.Event.FileCreated, function(file)
|
||||
vim.cmd("edit " .. file.fname)
|
||||
end)
|
||||
|
|
|
@ -2,7 +2,7 @@ return {
|
|||
{
|
||||
"kyazdani42/nvim-tree.lua",
|
||||
lazy = true,
|
||||
-- event = "BufRead",
|
||||
event = "VeryLazy",
|
||||
cmd = { "NvimTree", "NvimTreeOpen", "NvimTreeToggle", "NvimTreeFocus", "NvimTreeClose" },
|
||||
-- dependencies = "kyazdani42/nvim-web-devicons",
|
||||
config = function()
|
||||
|
@ -19,7 +19,7 @@ return {
|
|||
return
|
||||
end
|
||||
|
||||
local HEIGHT_RATIO = 0.8 -- You can change this
|
||||
local HEIGHT_RATIO = 0.9 -- You can change this
|
||||
local WIDTH_RATIO = 0.5 -- You can change this too
|
||||
|
||||
local icons = require("user.icons")
|
||||
|
@ -269,6 +269,11 @@ return {
|
|||
})
|
||||
end
|
||||
end
|
||||
-- auto open file if creation
|
||||
local api = require("nvim-tree.api")
|
||||
api.events.subscribe(api.events.Event.FileCreated, function(file)
|
||||
vim.cmd("edit " .. file.fname)
|
||||
end)
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue