mirror of
https://github.com/neovim/neovim.git
synced 2025-09-14 15:28:17 +00:00
terminal: Don't enter terminal mode from :normal
Ref: https://github.com/junegunn/fzf.vim/issues/8#issuecomment-139209765
This commit is contained in:
@@ -254,7 +254,16 @@ edit (
|
||||
)
|
||||
{
|
||||
if (curbuf->terminal) {
|
||||
terminal_enter();
|
||||
if (ex_normal_busy) {
|
||||
// don't enter terminal mode from `ex_normal`, which can result in all
|
||||
// kinds of havoc(such as terminal mode recursiveness). Instead, set a
|
||||
// flag that allow us to force-set the value of `restart_edit` before
|
||||
// `ex_normal` returns
|
||||
restart_edit = 'i';
|
||||
force_restart_edit = true;
|
||||
} else {
|
||||
terminal_enter();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user