O'Reilly logo

Mastering Vim by Ruslan Osipov

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Integrating Git with Vim (vim-fugitive)

This section assumes that you understand the basics of working with Git. If you don't (or it's been a while), see the Quick and dirty version control and Git introduction section.

Tim Pope's vim-fugitive is a plugin that makes sure you don't need to leave Vim to interact with Git. Since you're editing the files in Vim, you might as well take care of dealing with version control of said edits in the editor. The plugin is available from https://github.com/tpope/vim-fugitive.

If you're using vim-plug, you can install vim-fugitive by adding Plug 'tpope/vim-fugitive' to your .vimrc file and running :w | source $MYVIMRC | PlugInstall.

A lot of the commands vim-fugitive provides are a mirror of external Git ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required