I am trying to write a function which will send a Control-C character followed by RET.
If I am in the shell, I know that I have to do C-q C-c
to send a Control-C. I'd like to write a function that will just do this for me.
I've gotten as far as seeing that the quoted-insert
function is what I need to use but it's not clear to me from the docs on how to call it. Can anyone offer a pointer?
All I wanted to do was this:
(defun send-control-c ()
(interactive)
"Inserts quoted ^C into the buffer and hits enter"
(insert "")
(comint-send-input))