Managing plugins in Vim with Vundle
My website has moved to a new address: hund.tty1.se
Manually managing your plugins in Vim can be a tedious task, especially keeping them updated. But there’s several plugin managers to make life easier for you. I haven’t really tried a lot of them, but one that stood out for me personally was Vundle.
It’s a fairly simple and straight forward plugin manager that lets you install, uninstall, update and even search for plugins. Which is really all I can ask for.
Table of content
You install a plugins by first adding a line (sometimes two or more) into your
~/.vimrc file. Let’s say you want to install the plugin goyo.vim plugin. You then add this line to your configuration:
You then either restart Vim or resource your configuration with
:resource ~/.vimrc and then execute the command:
And you’re done! Do note that some plugins might require a second plugin or so, make sure to always read the installation instructions for the plugin you’re trying to install.
If you deicide you don’t want the plugin, you then just delete or comment out the line you just added to your configuration and then run the command:
Updating your plugins is just as easy as everything else, you just runt this command:
Searching for plugins
You can also search for plugins with the command:
Unfortunately you can’t see any information about the plugins from the search results. I never use the search feature myself, I just jump straight onto my search engine of choice to find what I’m looking for.
Spoiler: my search engine of choice is Searx.
Start by cloning the
Vundle.vim plugin to your Vim-folder:
$ git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
Then add this to your
set nocompatible " be iMproved, required filetype off " required " set the runtime path to include Vundle and initialize set rtp+=~/.vim/bundle/Vundle.vim call vundle#begin() " alternatively, pass a path where Vundle should install plugins "call vundle#begin('~/some/path/here') " let Vundle manage Vundle, required Plugin 'VundleVim/Vundle.vim' <Add your future content regarding Vundle here> " All of your Plugins must be added before the following line call vundle#end() " required filetype plugin indent on " required
Re-open or resource your configuration with
:source ~/.vimrc to apply the changes.