The 12 Best Vim Plugins to Improve Your Workflow

0

Vim is a widely used terminal editor in the Linux world, and like many other Linux applications, it also works on Unix, Windows, and macOS.

One of the things people love the most about Vim is that it’s highly customizable and extendable through plugins. Finding the right plugins for your workflow will dramatically improve your Linux productivity.

USE VIDEO OF THE DAY

Here is a selection of the 12 best Vim plugins that will improve your Linux workflow.

1. NERDTree

NERDTree is a file explorer plugin that allows you to view your project hierarchy directly in the Vim editor. Plus, you can use it to navigate complex folder structures and open files for editing. You can install NERDTree manually or with your favorite Vim plugin manager.

Once installed, you can open NERDTree using the Vim command : NERDTree.

Learn more or get help on this awesome file explorer using the following Vim command : NERDTree help. Use Vim’s built-in tutor to master this awesome editor.

To download: NERDTree

2. Emmet-vim

Emmet-vim is a powerful and flexible code completion plugin. It mainly targets web developers working with HTML and CSS. Emmet is more flexible and customizable than traditional snippets.

For example, to create three HTML links with emmet, you could just type li*3 and press the keyboard shortcut Ctrl+Y followed by , (comma) and emmet will automatically create the code for you. emmet is also available for other code editors such as VS Code, Atom, etc.

To download: Emmet-vim

3. vim-gitgutter

vim-gitgutter is a great tool if you use the Git version control system in your workflow. This plugin helps you keep track of your code by showing you all the changes you’ve made in your remote repository. For example, it highlights added, modified or deleted files.

Alternatively, if you use other version control systems such as Bazaar, Mercurial, Subversion, Darcs, etc., you can use the vim-means connect.

You can also use Git actions such as staging, previewing, and undoing code changes in your repository. vim-gitgutter comes with additional features like optional line highlighting, partial chunk staging, etc.

The plugin is inspired by a similar plugin available for the Sublime text editor. You can also use it with Vim’s line number feature to see which lines have changed.

To download: vim-gitgutter

You can easily comment and uncomment code in Vim with this awesome plugin. commentary.vim has very few commands and is extremely easy to use, even for beginners.

The most important command is gcc which comments out a single line of code. Use the command gc to comment out an entire selection when in visual mode.

commentary.vim is built on Vim’s support for mapping an operator. You can install the plugin through Vim’s plugin support or using your favorite plugin manager.

To download: comment.vim

5. vim-airline

vim-airline shows a nice status bar at the bottom that replaces the default one in Vim. The status line consists of several sections and gives you information such as the current cursor position in the file, file type, file format, etc. The different sections are colored distinctly to give you a good clue.

The theme, colors, and features of the plugin are easy to configure and can be customized to your liking. vim-airline is a lightweight and well-tested Vim plugin, and integrates well with other plugins such as fugitive, eclim, Flog, etc.

To download: vim-airline

6.fzf

Based on the general purpose command line finder, the fzf (fuzzy finder) plugin is basically a wrapper for the same. It contains a few commands that are easy to get used to, whether you are a beginner or an advanced Vim user.

The plugin is very light, super-fast and easy to install. The official fzf GitHub page has very good documentation on using the plugin.

To download: fzf

7. Fugitive

Fugitive is touted as one of the best Vim plugins for Git integration. The name Fugitive comes from the creators thinking it’s so awesome it should be illegal.

Fugitive works more like a wrapper of Git commands, and its syntax is very similar to that of Git. To run Git commands, just add the :git prefix to your commands. For example, to validate, use the Vim command :Commit GitWhere :git diff to show Git diff between multiple commits or branches.

Additionally, the plugin provides custom commands for higher-level operations, such as :Edit to show any commit, tree or tag in the repository, or :GDelete to run the git rm command on the current file. To move a file, you can use :GMove which is similar to the Git command git mv.

To download: Fugitive

8. Asynchronous Lint Motor (ALE)

The ALE plugin, short for Asynchronous Lint Engine, is a code analysis and lint tool that displays real-time warnings and errors as you make changes to your code.

In addition to linting, ALE also provides quick code fix suggestions with the :ALEFixSuggest ordered. It also supports code auto-completion. Even better, you can view more information about a symbol by hovering over it using the :ALEHover ordered.

ALE is well documented and you can access most of its documentation using the :to help ordered. For example, to get help on the hover function, you can run :help ale-hover.

ALE supports dozens of programming and scripting languages ​​such as C#, Bash, Ansible, Chef, SQL, JavaScript, YAML, TypeScript, C, LaTeX, etc.

To download: ALE

9. OmniSharp-vim

C# is a programming language originally developed by Microsoft and can only run on Windows. Fast forward so far, you can run C# on Windows, macOS, and Linux. And it doesn’t stop there, you can even develop C# code in Vim.

The OmniSharp-vim plugin is specially designed to help you easily write C# code in Vim. It provides code completion, code IntelliSense, and other necessary features to make writing C# code in Vim just as enjoyable. Other cool features supported include code refactoring, syntax highlighting, code formatting, running unit tests, and more.

To download: OmniSharp-vim

10.surround.vim

As the name suggests, the surround.vim plugin involves surrounding a piece of text or code with another character, specifically brackets, parentheses, quotes, etc. The plugin uses very simple commands to achieve its goal.

To download: surround.vim

11. Super Tab

Supertab helps you complete the insert via the Tongue key on your keyboard. Best of all, it’s easy to set up so you can customize it to suit your needs.

Use the vim command : help supertab for help with the plugin. You can use any of your favorite plugin managers or Vim’s built-in plugin support to install the plugin.

To download: Supertab

12. SnipMate

The main purpose of this plugin is to provide snippets similar to those supported in TextMate text editor to speed up your coding. For example, if you are using a C-based programming language to create a for loop, just enter “for” followed by Tongue key, and it will create the following code for you:

for (i = 0; i < count; i++) {
}

You can easily add your own custom snippets for your favorite programming language using SnipMate as well.

To download: SnipMate

Customizing Vim to Your Preferences Using Plugins

In addition to extending and providing additional functionality to Vim, plugins dramatically improve your workflow and productivity. There are thousands of Vim plugins available to you, and you can find the ones that best suit your workflow and install them for free.


If Vim’s default UI doesn’t amuse you, you can further customize the editor with its built-in customization features using the .vimrc case.

Share.

Comments are closed.