lambdalisue / vim-gina

👣 Asynchronously control git repositories in Neovim/Vim 8
http://www.vim.org/scripts/script.php?script_id=5531
MIT License
688 stars 27 forks source link

what is the best way to quit gina blame #78

Closed prabirshrestha closed 7 years ago

prabirshrestha commented 7 years ago

Currently when I use :Gina blame it shows the following UI.

I then use :q on the left and :bd on the right pane. Is there a mapping I can setup so that q can close both at the same time?

image

lambdalisue commented 7 years ago

If you close the right buffer (a content buffer) with :q, both window should be closed. If you close the left buffer (a navigation buffer), the right buffer remains for further operations.

If you feel this behavior is not enough for your usage, please explain the detail idea for the behavior and I'll consider 👍 or if you feel it is enough, just close this issue please.

bimlas commented 7 years ago

Closing content window with :q not works for me, tried out with :bdelete too: it's closing the content window, but blame window remains open (as the only one window).

I think an "exit from entire blame" mapping / ~command~ action would be useful.

bimlas commented 7 years ago

Opened #79 to add a mapping to exit from entire blame session.

lambdalisue commented 7 years ago

Sorry for late reply. Well probably closing is working as my expectation. The current implementation is

  1. Close both buffers if there are more than three windows
  2. Close a single buffer if there are exactly two windows while gina doesn't know what is the best way (quitting Vim or open a new buffer)
lambdalisue commented 7 years ago

https://github.com/lambdalisue/gina.vim/commit/da85b1953833033df358da43d88a0d894608d8ce