help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: An Eclim frontend for Emacs


From: Tassilo Horn
Subject: Re: An Eclim frontend for Emacs
Date: Tue, 21 Apr 2009 19:24:02 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.92 (gnu/linux)

Richard Riley <rileyrgdev@googlemail.com> writes:

Hi Richard,

> You're saying that eclipse completion features now work in emacs with
> company-mode?

Exactly.

> Wow? Is it trivial to set up?

Quite.  Here's my config.

--8<---------------cut here---------------start------------->8---
(require 'company)
(define-key company-mode-map (kbd "M-SPC") 'company-complete)

(defun th-turn-on-company-mode ()
  (interactive)
  (company-mode 1))

(dolist (hook (list
               'emacs-lisp-mode-hook
               'lisp-mode-hook
               'lisp-interaction-mode-hook
               'clojure-mode-hook
               'java-mode-hook
               'haskell-mode-hook
               'slime-repl-mode-hook
               'sh-mode-hook))
  (add-hook hook 'th-turn-on-company-mode))

(setq company-idle-delay nil
      company-eclim-auto-save t)

(setq company-eclim-executable
      "~/opt/eclipse/plugins/org.eclim_1.4.5/bin/eclim")

(defun th-java-mode-init ()
  (setq company-backend 'company-eclim))

(add-hook 'java-mode-hook 'th-java-mode-init)
--8<---------------cut here---------------end--------------->8---

And you need to install eclim, of course.  But it has an installer that
worked just fine for me.

> What about stuff like refactoring? Is there an eclim interface for
> that? Or context API help?  Or are those outside of the remit of
> eclim?

No, I think most if not all features are usable via eclim.  For
refactoring I don't know, but at least the eclipse incremental compiler
can be used to highlight errors in the code.  Same for any completion
functionality and things like "Organize imports".

That's all available for Vim right now, and I plan to start a project
which writes an emacs frontend.  But my time is quite limited at the
moment, so I don't know exactly when I get a first version which
implements some first features.  When I've done that, I'll announce it
and hope for many volunteers doing the work for me. ;-)

The git repo is already there:

  http://repo.or.cz/w/eclim-emacs.git

Bye,
Tassilo





reply via email to

[Prev in Thread] Current Thread [Next in Thread]