From 7aaeebd88b77d2400d597fec481a25db88ee7d27 Mon Sep 17 00:00:00 2001 From: Paulo Koch Date: Thu, 5 May 2011 02:54:44 +0100 Subject: [PATCH] Add option to close gundo on revert. --- plugin/gundo.vim | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/plugin/gundo.vim b/plugin/gundo.vim index 49cd83f..4f3c161 100644 --- a/plugin/gundo.vim +++ b/plugin/gundo.vim @@ -66,6 +66,9 @@ endif"}}} if !exists("g:gundo_map_move_newer")"{{{ let g:gundo_map_move_newer = 'k' endif"}}} +if !exists("g:gundo_close_on_revert")"{{{ + let g:gundo_close_on_revert = 1 +endif"}}} "}}} @@ -884,6 +887,9 @@ def GundoRevert(): vim.command('GundoRenderGraph') _goto_window_for_buffer(back) + if int(vim.eval('g:gundo_close_on_revert')): + vim.command('GundoToggle') + GundoRevert() ENDPYTHON endfunction"}}}