miércoles, 11 de noviembre de 2015

TIL: comint-send-string

I just learned a really powerful elisp function called `comint-send-string' . It's so easy to understand that probably a simple example will be enough.

  (comint-send-string "*shell*" "xclock\n")

Right, it sends a string to a comint buffer named "*shell*". you can use it to easily interact with any inferior process you have in your emacs. that means clojure repls, ruby repls (robe), etc....

1 comentario:

Anónimo dijo...

Very handy indeed, I never heard of that function in Elisp. Thanks for sharing!