1

I have successfully installed ensime, but I do not see any error highlighting in my code. I was sure there would be a Flymake for scala, but I can't seem to find it anywhere.

When I try to M-x flymake-mode in a scala buffer (with ensime connected,) I get:

couldn't require "flymake-for-scala"

How can I get flymake or something like it to work for scala in emacs?

DJG
  • 6,413
  • 4
  • 30
  • 51
  • I think `ensime` comes with its own versions of some popular libraries (one of the reasons I don't use it). You probably need to make sure `flymake` is loaded from `ensime` code rather then the one that comes with Emacs. –  Oct 14 '13 at 15:11
  • @wvxvw What do you use for editing scala if not ensime? What is your recommended setup? – DJG Oct 14 '13 at 18:47
  • @user1436026 A lot of folks use Intellij IDEA---the free community edition has Scala support. Moreover, IDEA has pretty good basic Emacs keystroke support. – Glenn Oct 14 '13 at 20:09
  • No-no, that's what I use, but I just don't use it quite as much. Ensime should do the job, unless you have some more setup going on in your `.emacs` (as is my case). I've looked into ensyme's code and it seems like it probably relies on flymake integration being provided with either `scala-mode` or `scala-mode-2` (have you installed any of those?). Also I'm not sure why would it require `flymake-for-scala`, that doesn't seem to appear in its code. How did you get your version of it? –  Oct 14 '13 at 20:16
  • @Glenn IDEA is an entirely different code editor... it is to Emacs like MS Excel is to World of Warcraft, fun-wise. It's really sad that people will chime into unrelated topic and suggest random stuff just because they like it :/ don't you think? –  Oct 14 '13 at 20:21
  • Ensime does not use flymake, but adds overlays manually (cf. `ensime-add-notes` in `ensime.el`). If you are missing error highlighting, check that your ensime connection is set up properly (eg, there should be an "ENSIME:" marker in the modeline) and look at the `*ensime-events*` or `*inferior-ensime-server*` buffers for output that might indicate what's wrong. – fgeller Oct 16 '13 at 20:14

0 Answers0