Almost every action is supported(except for undo/redo and replace mode), even actions from plugins such as 'ds' from nvim-surround
- Neovim 0.11+
via lazy.nvim
{
'xb-bx/editable-term.nvim',
config = true,
}
By default the plugin only detects OSC 133 promt lines but you can extend it to support REPLs that dont support OSC 133.
local editableterm = require('editable-term')
editableterm.setup({
promts = {
['^%(gdb%) '] = {}, -- gdb promt
['^>>> '] = {}, -- python PS1
['^... '] = {}, -- python PS2
['some_other_prompt'] = {
keybinds = {
clear_current_line = 'keys to clear the line',
goto_line_start = 'keys to goto line start',
forward_char = 'keys to move forward one character',
}
},
},
})
{
clear_current_line = '<C-e><C-u>',
forward_char = '<C-f>',
goto_line_start = '<C-a>',
}
add following to your shell's rc file
if [ -z "$NVIM" ]; then
set -o vi
fi