-1

I am new to vim, I watched this video and wish to give it a good try for a month to see how I like it.

I want to add the NERDTree plugin to my vim, I'm actually using NeoVIM:

NVIM v0.4.4 Build type: Release LuaJIT 2.0.5 

I Googled and found this article. It seemed straightforward but when I followed the steps, it doesn't seem to work for me, so I guess I'm missing something.

~|⇒ ls ~/.vim/pack/vendor/start nerdtree ~|⇒ ls -l ~/.vim/pack/vendor/start/nerdtree total 164 drwxr-xr-x 3 jwan jwan 4096 Feb 21 11:29 autoload -rw-r--r-- 1 jwan jwan 30828 Feb 21 11:29 CHANGELOG.md -rw-r--r-- 1 jwan jwan 26 Feb 21 11:29 _config.yml drwxr-xr-x 2 jwan jwan 4096 Feb 21 11:29 doc drwxr-xr-x 3 jwan jwan 4096 Feb 21 11:29 lib -rw-r--r-- 1 jwan jwan 474 Feb 21 11:29 LICENCE drwxr-xr-x 2 jwan jwan 4096 Feb 21 11:29 nerdtree_plugin drwxr-xr-x 2 jwan jwan 4096 Feb 21 11:29 plugin -rw-r--r-- 1 jwan jwan 8429 Feb 21 11:29 README.markdown -rw-r--r-- 1 jwan jwan 87896 Feb 21 11:29 screenshot.png drwxr-xr-x 2 jwan jwan 4096 Feb 21 11:29 syntax 

According to the article, that should be all that I have to do! The article says:

Now you can place Vim plugins in ~/.vim/pack/vendor/start, and they'll automatically load when you launch Vim.

That doesn't seem to happen for me! When I have vim open and I type :NERDTree I just get:

E492: Not an editor command: NERDTree 

What am I missing?

7
  • 1
    If not duplicates, at least related questions How do I install a plugin in Vim/vi? and What is the Vim8 package feature and how should I use it?. FWIW I created the same file hierarchy and cloned github.com/preservim/nerdtree in start and :NERDTree is available, maybe check :messages for any error message. Commented Feb 22, 2021 at 10:37
  • Thanks @statox, indeed, both are related. I read them before asking my question, sadly I was none the wiser. The first question is mostly about plugin managers. The second one is what I'm after but after following the steps I can't get it to work, I'm not sure what I'm missing. Commented Feb 22, 2021 at 10:38
  • 1
    Have you tried with an orginal vim8 instance rather and neovim? And as I said in my edit in my previous comment, maybe check for error messages in :messages, also check if :scriptnames mentions NERDTree Commented Feb 22, 2021 at 10:39
  • 1
    See :help standard-path. Also :help vim-differences. Commented Feb 22, 2021 at 11:09
  • 1
    Welcome to Vi and Vim! Commented Feb 22, 2021 at 15:24

2 Answers 2

0

I couldn't deal with the hassle. So I just installed neovim and installed standalone vim. I figured most online articles and documentation will refer to standalone vim too.

Things worked straight away.

enter image description here

0

I would just stick to pathogen until you get familiarized with how things work. I started moving things to the 'pack/yourname/start' one day and things started breaking. That being said I am working on a plugin and 'pack/myname/start' seems to work fine. Pack is a great way to separate your plugins. If you notice tpope plugins usually go in there.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.