nvim-editcommand icon indicating copy to clipboard operation
nvim-editcommand copied to clipboard

prompt may change if user enters an interpreter

Open brettanomyces opened this issue 9 years ago • 2 comments

If a user enters a interpreter from within the terminal. e.g. python, then the prompt may change, $ -> >>>. We should provide a mechanism to automatically update the prompt, and reset the prompt, when the user leaves the interpreter.

To do this we could remap <cr> to run some commands if the current command is python/lua/ruby/etc.. and the same for whatever command is used to exit the interpreter. We will also need to handle the case where the user uses control characters, e.g. ^C, to leave the interpreter.

brettanomyces avatar Feb 11 '16 21:02 brettanomyces

I'll probably implement this in nvim-terminus first and port it back if it makes sense to do so.

brettanomyces avatar Feb 11 '16 21:02 brettanomyces

Perhaps just enable a regex for editcommand_prompt? I'm currently doing let g:editcommand_prompt = '#' for psql.

Btw, thanks a lot for nvim-editcommand, really useful!

steve-chavez avatar Jan 16 '21 21:01 steve-chavez