Issue installing vim plugins - vim

So i'm rocking a VIM version 6.3.82 on rhel 4.9... which i'd imagine is the biggest culprit. (no chance of an upgrade any time soon)
I downloaded the latest Rails.vim and have installed this many times on my home machine.
I try the command :Rails! and i Get "e493: Not an editor command."
In my .vimrc i've added
set nocompatible
syntax on
filetype plugin indent on
Am i doomed with a dated vim to use most any plugins? Am i missing something in my .vimrc to enable vim plugins?
Any direction is appreciated. :p-
TIA,
Kirby

You'll need to use an old version of Rails.vim it looks like. The last version that worked with Vim 6 is version 2.1:
http://www.vim.org/scripts/script.php?script_id=1567
You may be able to compile your own version of vim in your home directory if you want to use the latest Vim and Rails.vim.

Related

Problem loading ~/.ideavimrc from PyCharm

I installed PyCharm on Ubuntu 18.04 by extracting the tarball into /etc/ and creating a shortcut through the Tools menu.
I installed IdeaVim through the marketplace, and the Vim plug-in is working as expected.
Now I want to import my vim settings from my .vimrc. I just copied the .vimrc to ~/.ideavimrc and reloaded my IDE. However, my remappings are not working. I tried sourcing the rc file using :source ~/.ideavimrc, but this doesn't work either.
The only content of my .ideavimrc file is this line:
xnoremap p pgvy
I really hate the paste-setting of vim, so I need this remapping and I'm lost. Thanks for the help.
This was an actual bug with Idea VIM plugin and the .ideavimrc file, found here.
It has been resolved since.

How to add python support for vim without destroying up all the plugins?

I started using vim earlier this summer and have recently started to add plugins. Todays challenge is to install YouCompleteMe.
Problem: During the installation process I noticed that my vim version (7.4) doesn't have support for python/python3.
Question: How can I fix this without messing up all my plugins/.vimrc file?
Will a clean install even affect my plugins/.vimrc?
I read some where that I should install 'vim-nox'.. Should I?
My setup: Ubuntu 16.04. Vim 7.4. Plugins are installed via Pathogen.
Thanks in advance for your replies!
Kind regards, Edvin
As long as your plugins are installed in $HOME/.vim (or MsWindows equivalent), and not into /etc/vim or /usr/share/vim, there should be no problem: you can upgrade your vim version without impacting what you have already installed.
See :h 'rtp' and :h startup.
Plugins and vimrc are just files. They can't be executed stand alone. Further, they come into power, only when vim is running.
So, your uninstallation/installation of vim doesn't change/affect plugins or vimrc. However, if the plugin or vimrc has code related to specific environment (like OS, terminal, etc,.) or needs specific features of vim and if your new version doesnt support them, you may have problems. Plugins in default folder(where vim is installed) will get deleted when you uninstall. The plugins in HOME directory aren't affected anyway.

Lack of file explorer in Linux vim

In vim 7.3 on OSX, if I type
vim ~/myfiles
vim will put me into the Vim File Explorer for that directory, and I can open or rename files.
In vim 7.4 on Ubuntu, I get the unhelpful error message
"~/myfiles" is a directory
Looking through the compiled options (vim --version) and online documentation, I see no obvious way to activate this functionality through, say, a command-line or compile-time option. It is such a great feature of vim that I'm surprised it is not enabled on the version of vim available in the Linux package.
Use the :E command for the explorer mode.
The ability to edit a directory like this depends on a plugin. Most of the time, that plugin is the "netrw" plugin provided with Vim in the official runtime files. In Ubuntu (and Debian) you install that runtime separately so that every Vim package can use it rather than duplicating functionality. Try installing the vim-runtime package, and maybe a more feature-full Vim while you are at it, if you have not already done so.
To summarize and answer my own question...
File explorer functionality is actually provided by a plug-in, "netrw", which seems not to be installed by default in the two or three versions of vim I tried via apt-get.
Installing NERDTree solved the problem brilliantly - it can do so much more than the default explorer. I have not yet figured out how to rename a file using NERDTree - something that is easy with 'netrw', but that is a minor irritant and there is probably a way to do it.

vundle/YouCompleteme: requires Vim 7.3.584+

I have a error when i use vim. After I place this line in .vimrc
Plugin 'Valloric/YouCompleteMe'
and
:PluginInstall
error:
YouCompleteMe unavailable:
My vim : VIM - Vi IMproved 7.3
Anyone's know how to fix it ?v
The :version command tells you the exact Vim version. If you grabbed the official installer from vim.org, you probably have 7.3.000. As Vim 7.4 has been released, it's the easiest to upgrade to that version.
If you have the problem with Homebrew version on Mac, try the following as officially documented. Please make sure you're running vim not vi on your mac.
cd ~/.vim/bundle/YouCompleteMe
./install.sh

Going from vim 7.3 to 7.2

I am trying to install commandT plugin and vim 7.3 has no ruby support and i am a newbie to vim. i don't think i know how to complile ruby support myself. If i go back to vim 7.2 will i be missing out on anything that 7.3 has to offer?
Once you have installed Vim 7.3 you can find all the details about the changes since Vim 7.2 with:
:help version-7.3
Persistent undo is really nice, it would be a shame to live without that.
If you're running vim for Windows you could try installing Cream, from here: http://www.vim.org/download.php#pc. That package contains vim 7.3 plus ruby support plus other goodies.
relativenumber is working really well for me.

Resources