How to start VIM with NERD tree opened automatically? [duplicate]
Asked Answered
G

1

25

Possible Duplicate:
Auto-open NERDTree in “EVERY” tab

Is there a way to automatically execute the :NERDTree command when VIM is launched for the first time or configure NERDTree to always open on startup?

PLEASE CLOSE. Just noticed that this question was answered before:
Auto-open NERDTree in "EVERY" tab

Gisborne answered 24/9, 2010 at 16:6 Comment(0)
P
44

Yes. Just write this line to your .vimrc :

autocmd VimEnter * NERDTree
Putscher answered 24/9, 2010 at 16:8 Comment(6)
This doesn't work for meFenn
@droope: do you have the NERDTree plugin installed?Putscher
hi @benoit, in the end i solved it with this :) many thanks #1980020Fenn
autocmd VimEnter * NERDTreeHarrie
@MostafaShahverdy's answer worked for me, Benoit's didn'tDiarthrosis
if you don't want to have to switch focus every time: https://mcmap.net/q/173624/-how-to-add-nerdtree-to-your-vimrcEttaettari

© 2022 - 2024 — McMap. All rights reserved.