Closed itchyny closed 3 years ago
I see... Do you know any workaround for this?
Removing the following line may fix the issue but not sure it breaks other behaviors. https://github.com/lambdalisue/gina.vim/blob/7069668147157d872821ebed1eee07742ece48fd/autoload/gina/command/commit.vim#L318
Hum... That would break the behavior of :q
which should show the prompt otherwise unwilling commit will be performed.
How about checking the last command then?
if histget('cmd', -1) !~# '^\(wq\|x\%[it]\|exi\%[t]\)'
silent! unlet b:gina_BufWriteCmd
endif
This is not perfect and does not work with ZZ
though (should not prompt). But note that ZQ
is unchecked (in L309) and invokes the commit unlike :q!
.
Nice. Would you mind if I ask you to create a PR for that?
Using
:wq
on gina-buffer-commit feature, gina is expected not to show confirmation prompt.However, starting from vim 8.2.2900, which fixes the issue https://github.com/vim/vim/issues/8279, the plugin starts to show confirmation prompt. It seems that the commit in Vim breaks the assumption of gina at https://github.com/lambdalisue/gina.vim/blob/97116f338f304802ce2661c2e7c0593e691736f8/autoload/gina/command/tag/edit.vim#L111.