Ⅰ. 插件描述

gitk for Vim.

Ⅱ. 基本信息

创建日期:  2011-04-24
使用用户:  1459
Github星:  923
插件作者:  Greg Sexton

Ⅲ. 安装方法


Plugin 'gregsexton/gitv'
… 然后在Vim中运行以下命令:
:source %

对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。


NeoBundle 'gregsexton/gitv'
… 然后在Vim中运行以下命令:
:source %


Plug 'gregsexton/gitv'
… 然后在Vim中运行以下命令:
:source %


cd ~/.vim/bundle
git clone

Ⅳ. 文档说明

# Maintainers Needed

I am no longer maintaining this project as I no longer use Gitv.
If you would like to maintain this project, please email gregsexton.


gitv is a repository viewer similar to gitk. It is an extension of the
fugitive git plugin for vim. It is essentially a wrapper around
git log --graph, allowing you to see your branching history. It allows you to
view commits, diffstats, inline diffs, and file or folder specific history, and

  1. It allows you to perform operations on the commit tree interactively,
  2. as merges, cherry picks, reversions, resets, deletions, checkouts,

bisections, and rebase operations.

This repo has the most bleeding edge version of gitv. Stable versions are
available at the page.

Bugs, suggestions, pull requests and patches are all very welcome.

We are currently actively looking for feature requests and bugs regarding the
latest pre-release.

Basic usage

Start the plugin by running :Gitv in Vim when viewing a file in a git repository.

This plugin is an extension of the fugitive git plugin by Tim Pope.

I hope you like it!


You will need the tpope/fugitive plugin installed and working for gitv to work.

For Windows, use the ~\vimfiles directory instead of ~/.vim

MethodInstalation instructions
ManualMerge the autoload, doc, ftplugin, plugin, and syntax folders into their respective ~/.vim folders
NeoBundleAdd NeoBundle 'gregsexton/gitv' to .vimrc
PathogenRun git clone ~/.vim/bundle/gitv
PlugAdd Plug 'gregsexton/gitv', {'on': ['Gitv']} to .vimrc
VundleAdd Plugin 'gregsexton/gitv' to .vimrc


gitv was developed against Vim 7.3 and later 8.0 but earlier versions of Vim
should work. Vim 7.2+ is recommended as it ships with syntax highlighting for
many Git file types. Vim 7.3+ is recommended for UTF-8 support.

gitv now has basic neovim support.


gitv is a 'gitk clone' plugin for the text editor Vim. The goal is to give you
a similar set of functionality as a repository viewer. Using this plugin you
can view a repository's history including branching and merging, you can see
which commits refs point to. You can quickly and easily view what changed to
which files and when. You can perform arbitrary diffs (using Vim's excellent
built in diff functionality) and you can easily check out whole commits and
branches or just individual files if need be.

Throw in the fact that it is running in Vim and you get for free: the ability
to move over repository history quickly and precisely using Vim's built in
movement operators. You get excellent code syntax highlighting due to Vim's
built in ability. You can open up all sorts of repository views in multiple
windows and position them exactly how you like. You can take advantage of Vim's
registers to copy multiple fragments of code from previous commits. The list
goes on.


Click here for help on our official server.

Future changes are viewable in the roadmap.

A tentative release schedule is available in the milestone view.

You can download stable release versions (and vote for gitv!) at
gitv’s page on


commit preview

gitv commit preview

diff splitting

gitv diffsplit

diff stat-ing

gitv diffstat

interactive bisecting

gitv interactive bisecting

interactive rebasing

gitv interactive rebasing