nickjj / dotfiles

Settings for various tools I use.
https://nickjanetakis.com/blog/the-tools-i-use
MIT License
952 stars 183 forks source link

vim error E492: Not an editor command: ++nested call s:hijack_directory() #7

Closed awunnenb closed 4 years ago

awunnenb commented 4 years ago

on Ubuntu 18.02 and Vim 8.0.x i got this Error: vim error E492: Not an editor command: ++nested call s:hijack_directory()

Problem in this row: autocmd BufEnter * ++nested call s:hijack_directory()

with vim 8.2 it works fine, but this version is not in the official apt-repo.

nickjj commented 4 years ago

Hi,

It should work with Vim 8.1 too for reference.

In this case, it's an example taken from Fern (a plugin). I just opened an issue for it at https://github.com/lambdalisue/fern.vim/issues/201.

Thanks for the report. If the author of that plugin doesn't provide a working example with 8.0 I may need to mark my vimrc to only work with 8.1+ because I wouldn't know how to fix that.

Edit:

Just for future reference, running sudo add-apt-repository ppa:jonathonf/vim before this dotfiles's instructions for installing Vim should work for Ubuntu 18.04, that will grab Vim 8.2. If need be, I'll update the docs to include this as well. But let's see if an 8.0 fix can be made since AFAIK I don't use anything else in my vimrc that only works with 8.1+.

nickjj commented 4 years ago

Turns out Fern requires Vim 8.1+.

Installing Vim from the PPA listed above will get you going on Ubuntu 18.04.

I've also updated my vimrc to mention needing Vim 8.1+ and included better installation instructions for multiple distros in the README at https://github.com/nickjj/dotfiles#quickly-get-set-up-with-these-dotfiles.