From 75a27559a3b22d4eb6d2575903e6579a99fad16e Mon Sep 17 00:00:00 2001 From: Adam George Date: Mon, 26 Mar 2012 15:02:08 +1100 Subject: [PATCH] Add an `S` mapping for vertical splits from :Gstatus --- doc/fugitive.txt | 5 +++++ plugin/fugitive.vim | 2 ++ 2 files changed, 7 insertions(+) diff --git a/doc/fugitive.txt b/doc/fugitive.txt index d1514ff..e102f91 100644 --- a/doc/fugitive.txt +++ b/doc/fugitive.txt @@ -53,6 +53,7 @@ that are part of Git repositories). p |:Git| reset --patch (staged files) q close status R reload status + S |:Gvsplit| *fugitive-:Gcommit* :Gcommit [args] A wrapper around git-commit. If there is nothing @@ -232,6 +233,10 @@ These maps are available in Git objects. *fugitive-o* o Jump to the revision under the cursor in a new split. + *fugitive-S* +S Jump to the revision under the cursor in a new + vertical split. + *fugitive-O* O Jump to the revision under the cursor in a new tab. diff --git a/plugin/fugitive.vim b/plugin/fugitive.vim index a3ec3cf..10d2220 100644 --- a/plugin/fugitive.vim +++ b/plugin/fugitive.vim @@ -2172,6 +2172,7 @@ function! s:JumpInit() abort nnoremap :exe GF("edit") if !&modifiable nnoremap o :exe GF("split") + nnoremap S :exe GF("vsplit") nnoremap O :exe GF("tabedit") nnoremap - :exe Edit('edit',0,buffer().up(v:count1)) nnoremap P :exe Edit('edit',0,buffer().commit().'^'.v:count1.buffer().path(':')) @@ -2179,6 +2180,7 @@ function! s:JumpInit() abort nnoremap C :exe Edit('edit',0,buffer().containing_commit()) nnoremap cc :exe Edit('edit',0,buffer().containing_commit()) nnoremap co :exe Edit('split',0,buffer().containing_commit()) + nnoremap cS :exe Edit('vsplit',0,buffer().containing_commit()) nnoremap cO :exe Edit('tabedit',0,buffer().containing_commit()) nnoremap cp :exe Edit('pedit',0,buffer().containing_commit()) endif