Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to Make Eclipse More Like Emacs

Tags:

emacs

eclipse

ide

I am very familiar with emacs--and I realize that there is nothing that it cannot do--but there are some things that it does not do well or efficiently. So, being between projects I am open to the idea of switching to a full-featured IDE such as Eclipse.

With muscle-memory being what it is, I would like to make Eclipse as emacs-like as possible. I have already discovered the excellent Emacs+ plugin which gets me about halfway there. However, I am still missing the following features of emacs which I routinely rely upon:

  • shell: It's not just a shell, it's also a buffer.

  • occur: Search->File... is close to what I want, but I just want it to search the current file--which might be a text file, a logfile, or a shell buffer, or whatever.

  • align-regexp: This awesome little command in emacs helps me make files more readable, and alignment helps with keyboard macros.

What plugins would you recommend to solve these issues? Are there any other emacs features you miss in Eclipse or plugins you would recommend?

Please, no emacs/vi zealots asking why on Earth I would do such a thing.

like image 333
Brian Avatar asked Jan 19 '10 18:01

Brian


1 Answers

  • For the shell you have WickedShell

Shell view

  • Ctrl+F is enough to trigger a Search within the current file. (does not create a new buffer with matched lines)
    Only Mark Occurrences is about highlighting occurrences, but that is not as advanced as the Emacs function.

Mark Occurrences

  • Formatter options can emulate "align-regex" function, as described here.

Preferences -> Java -> Code Style -> Formatter.
Click 'Edit' on the profile (you may need to make a new one since you can't edit the default).

In the indentation section select 'Align fields with columns'.

Then, in your code Ctrl+Shift+F will run that formatter.

like image 53
VonC Avatar answered Oct 04 '22 19:10

VonC