Using Kawa in Emacs

590 views Asked by At

Are there any modes or resources for Kawa in Emacs? I've checked, but am not able to find any. Mostly, I'd like to be able to run a Kawa REPL inside of Emacs, but some kind of completion/syntax checking would be great too.

1

There are 1 answers

0
Wenshan On BEST ANSWER

I don't have any prior experience with Kawa, but I have a "universal" way to deal with REPLs: plugin isend + some hacks

  1. Follow the instructions in section 2 and section 3 of this article http://wenshanren.org/?p=351#sec-2 to setup isend (it's a bit tedious, please let me know if you have any problems)

  2. Open a shell in Emacs, assume the buffer name is *shell*

    M-x shell

  3. Open Kawa REPl in *shell*

    CLASSPATH=/usr/local/lib/kawa.jar && export CLASSPATH && java kawa.repl

  4. Create a new buffer test.kawa and turn on lisp-mode M-x lisp-mode (you can use any mode you want)

  5. Associate *shell* with test.kawa M-x isend-associate *shell*

  6. Now type some sexps in test.kawa, select them and press C-Enter to send them *shell* for execution (the cursor won't move)

enter image description here