From 4804c7113e449bbf9eb22d368ef61c75a19caec6 Mon Sep 17 00:00:00 2001 From: Nydragon <6582485n@proton.me> Date: Sun, 12 Feb 2023 19:40:49 +0100 Subject: [PATCH] nvim tree is now automatically opening --- firefox/cookie_cache | Bin 196608 -> 196608 bytes nvim/lua/nvim-tree-config.lua | 13 ++++++++++++- nvim/lua/plugins.lua | 2 -- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/firefox/cookie_cache b/firefox/cookie_cache index 35d182c0ce1f6901bd998255681c9cdb13f489ef..ad4fafc9ed39f3e5790e3508833c58824d772d08 100644 GIT binary patch delta 132 zcmZo@;Av>!nIO#=K2gS*F}yKhYXak?qnwMc_%pV-Jze3y-TD}#mNw_|mFYnK%i4_X zc^?_y32`pAeg=}~e>Odpg~^n2@oaq%H(!7HViqPN&bcpwf!zChg16seVRB>QT$pwV f$bW2gX}c~v)1DB{rAvPR`OhnVZ2uI^#J2!nIO&RGf~Ew(WfzCYXak?qnsTvKN#EGP8s~zZheeVOPh1@Aub^Q>NM`{ zc^?_y330X`=?C&p&gh?>%EDyI*|2Ikkb9_Z`SissOh%m5+$(_GJ@;2^zsJJl#>CnB hJ{`zEemH%*E<4kn5YDVUSAhIA6RvFk6wSo91OR-@HHZKJ diff --git a/nvim/lua/nvim-tree-config.lua b/nvim/lua/nvim-tree-config.lua index 8febdb1..ce6e255 100644 --- a/nvim/lua/nvim-tree-config.lua +++ b/nvim/lua/nvim-tree-config.lua @@ -1 +1,12 @@ -vim.g.nvim_tree_auto_open = 1 +vim.g.loaded_netrw = 1 +vim.g.loaded_netrwPlugin = 1 + +require("nvim-tree").setup() + +local function open_nvim_tree() + + -- open the tree + require("nvim-tree.api").tree.open() +end + +vim.api.nvim_create_autocmd({ "VimEnter" }, { callback = open_nvim_tree }) diff --git a/nvim/lua/plugins.lua b/nvim/lua/plugins.lua index 4b1e377..ae52d1c 100644 --- a/nvim/lua/plugins.lua +++ b/nvim/lua/plugins.lua @@ -49,8 +49,6 @@ return require('packer').startup(function(use) -- setup section - require('nvim-tree').setup() - require('nightfox-config') require('nvim-tree-config')