-
I want to open nvim-tree in startup and following this and this, I made this lua file in
But doing that overrides the default "look"/"options" of nvim-tree, the one provided by NvChad. I am aware that this is caused by the line And so I was just wondering if their is a way to open nvim-tree on startup while keeping the NvChad's setup. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
@FosRexx you can run the open() in vim.schedule or vim.defer_fn |
Beta Was this translation helpful? Give feedback.
-
After learning more about neovim I did this quite differently than the original answer, I wont explain the reasons much here be I will just share what I have done. First i added this line at the end of
Then I created a Then I created a
Now I again created a new file named
This setup works and nvim-tree opens on startup. |
Beta Was this translation helpful? Give feedback.
After learning more about neovim I did this quite differently than the original answer, I wont explain the reasons much here be I will just share what I have done.
First i added this line at the end of
~/.config/nvim/init.lua
file:Then I created a
custom
directory in~/.config/nvim/lua/
, now we have a directory like~/.config/nvim/lua/custom/
Then I created a
init.lua
file inside~/.config/nvim/lua/custom/
. Now in~/.config/nvim/lua/custom/init.lua
, I added this line:Now I again created a new file named
nvimtree.lua
inside~/.config/nvim/lua/custom/
. Now in~/.config/nvim/lua/custom/nvimtree.lua
, I added this which is copied directly from the …