Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Insert mode in repl window is not exited after debugging ends #33

Closed
brymko opened this issue Jun 18, 2021 · 1 comment
Closed

Insert mode in repl window is not exited after debugging ends #33

brymko opened this issue Jun 18, 2021 · 1 comment

Comments

@brymko
Copy link

brymko commented Jun 18, 2021

The moment debugging stops all windows automatically close. If we are currently in insert mode in the REPL window (i.e step through the entire program (NOT IF .exit is executed)) we are thrown into insert mode in the code window.
Now the real problem is the fact that the stuff you accidentally inserted isn't undoable.
Don't know if this is a bug by neovim (im on v0.5.0-dev+1423-ge2d3ad7bc)
However i've managed to fix this by manually going into normal mode after the window closes. Inserting this

function M.on_close()
    local key = vim.api.nvim_replace_termcodes("<Esc>", true, false, true)
    vim.api.nvim_feedkeys(key, 'n', true)
end

into

function M.on_close()
here.

@rcarriga
Copy link
Owner

This is an annoying issue... Prompt buffers seem to be pretty funky right now. Thanks for flagging!

Please try with the latest commit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants