When executing :Gblame, it opens up a window for the blame information. When close that window with q, I want to execute wincmd =

I've tried the following, they don't seem to work:

autocmd BufLeave fugitiveblame wincmd =
autocmd BufLeave *.fugitiveblame wincmd =
autocmd WinLeave fugitiveblame wincmd =
autocmd WinLeave *.fugitiveblame wincmd =

This is also an issue with the ctrlsf plugin. I would like to do the same thing.

Any help would be appreciated!

Edit: I guess what I'm after is the ability to re-equalize the window sizes after closing the blame or ctrlsf windows.

  • You could try QuitPre.
    – Tumbler41
    Commented Feb 21, 2017 at 22:48
  • @Tumbler41 I don't think it would work, doesn't that get called before :q actually closes the window? If I equalize the windows at that point, they'll be un-equalized after the blame window closes
    – synic
    Commented Feb 21, 2017 at 22:49

1 Answer 1


Maybe not exactly as requested, but it seems to work:

autocmd FileType fugitiveblame nnoremap <buffer> q :q<CR>wincmd =

So this will work only if you close Gblame buffer with q


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.