After two years I still loathe Eclipse, and my former love NetBeans is now from a bad neighborhood, and more and more people I respect are switching to IntelliJ Idea. So I thought I’d give it a try, since I’m just starting on a project that might grow large-ish. This is going to be a diary of the experience, heavily loaded with GoogleBait in case others encounter some of the same pain points that are inevitable in such a transition.

Error: Module not specified · Importing projects from Eclipse to Idea is a little tricky. First (I didn’t do this) you gotta learn the lingo.

I had real trouble, perhaps because my Eclipse setup is a little nonstandard; the “workspace” directory isn’t the one the actual projects live in. Eventually I got IntelliJ to realize that the current guinea-pig project was a ”module“ and even apparently try to compile it, but then when I ran it, I was up against a brick wall of “Error: Module not specified”, and the drop-down from which you pick the module didn’t have any to pick.

Lots of random poking around made it obvious that Idea didn’t realize that my $(PROJECT)/src directory was where the source was, and I found that the menu produced by right-clicking on it included “Mark directory as” with an option to mark it as “Source Root”. Then everything sort of fell into place, and I could run the project on my phone.

I’ve remarked before that picking up a new IDE is always going to be tough, because the first thing you have to do is create a project, and that has to be one of the most gnarly, complex, option-laden functions any IDE provides.

Next Steps · First I need to get my emacs navigation keystrokes back, then I need to figure out what Idea is actually doing when it lets me place the cursor in floating whitespace 30 past the end of a line (not inserting spaces, I really hope).



Contributions

Comment feed for ongoing:Comments feed

From: Dmitry Jemerov (Mar 30 2012, at 09:21)

Regarding the second of your next steps: please turn off Editor | Virtual Space | Allow placing caret after end of line. And don't worry about the whitespace: by default we trim the whitespace at the end of all modified lines in your files.

[link]

From: James Roper (Mar 30 2012, at 09:22)

With IntelliJ allowing placement of the cursor after the end of the line... I hate that too. But it's easy to turn off. Preferences -> Editor, and on that screen there is a checkbox "Allow placement of caret after end of line". Also, a really nice feature of IntelliJ preferences is the search box. Type what you want to do in it, and it will highlight all the areas of the preferences that have that word. I wish you all the best with IntelliJ, it took me a while to switch from Eclipse too, but now I love it so much I would never go back.

[link]

From: Marshall Pierce (Mar 30 2012, at 09:35)

Settings > Keymap > "Keymaps" popup > Emacs

I don't use Emacs so I don't know how faithful it is, but it's probably at least a good start!

Other settings I always apply:

Settings > Editor

- All boxes under "Highlight on Caret Movement"

- "Next error goes to errors first" (F2 by default)

Check out http://stackoverflow.com/questions/294167/what-are-the-most-useful-intellij-idea-keyboard-shortcuts for more good stuff.

[link]

From: Ken Kinder (Mar 30 2012, at 11:00)

For what it's worth, I've been using PyCharm for my Python hacking needs, which is based on the same platform as IntelliJ.

It's definitely a solid tool and a lot of the IDEA-wide features are extremely useful. I really have enjoyed the VCS integration; it's surprising how well-done it is given how many systems they support. Another nice feature, which is rough around the edges but still usable, is "deployments": quickly copy code to a server for testing without having to use a remote filesystem.

IDEA also just seems a little cleaner and easier to use than Eclipse. Things happen faster, it's easier to learn, commands are simpler, etc.

[link]

From: dr2chase (Mar 30 2012, at 12:04)

I'd be interested in knowing about support for Scala and mixed Scala/Java projects, especially compared to Eclipse.

[link]

From: Kieron Wilkinson (Mar 30 2012, at 12:30)

I've often wondered why the virtual space is on by default. It's always the first thing I turn off :)

[link]

From: Bart Schuller (Mar 30 2012, at 12:48)

Getting an IDE to understand your project structure is much easier when you use a more formal way of setting up projects. Yes, I mean maven.

Although it doesn't actually have to be maven. Both Eclipse and IntelliJ have support or plugins for a wide range of build tools, so if you pick any one of them that has a good dose of convention/configuration, you can't go wrong.

I'm happily using sbt for downloading the internet, but that's because I'm very happy with Scala. I can use the command-line or any IDE and all will understand the project structure

[link]

From: Matthew Montgomery (Mar 30 2012, at 13:01)

I've not tried the Scala plugin but here is where you can read about it.

http://confluence.jetbrains.net/display/SCA/Scala+Plugin+for+IntelliJ+IDEA

[link]

From: Matěj Cepl (Mar 30 2012, at 13:55)

Would you mind to write down what was it that you hated on Eclipse the most, or why did you loathe it so much? That could be the interesting story to ready.

[link]

From: Cedric (Mar 30 2012, at 23:42)

The first rule when learning a new tool is: learn the native language, don't try to map your own keybindings over the native ones or you will miss out on a lot of features.

You're not using emacs, there is no reason to use emacs keybindings any more. Embrace the new world.

Believe it or not, one day you will wonder how anyone could think that "\Cn" is the natural way to go down one line.

[link]

From: Tony Fisk (Mar 31 2012, at 18:30)

From your tweets on the issue, I *thought* the problem might be with the search path.

After several years of playing with Delphi and Visual Studio, I have come to take Tolkien's advice to heart:

"Do not meddle in the affairs of wizards, for they are subtle and quick to anger."

... as well as lead you down the garden path before abandoning you to the compost fairies.

A text editor does for me.

[link]

From: Gordon J Milne (Apr 02 2012, at 03:06)

Good luck on the move. I much prefer IDEA over Eclipse. It clearly separates the JDK for your development from the JRE that the IDE is running under. Eclipse constantly confuses me on that point and I struggle to relearn the difference every time I come back to Eclipse.

My favourite feature in the IDE is ctrl-w/shift-ctrl-w for extend/contract selection. I understand Eclipse has this feature now but I first came across it in IDEA and I now find that my fingers' muscle memory does the rest.

[link]

author · Dad
colophon · rights
picture of the day
March 30, 2012
· Technology (90 fragments)
· · Software (82 more)

By .

The opinions expressed here
are my own, and no other party
necessarily agrees with them.

A full disclosure of my
professional interests is
on the author page.

I’m on Mastodon!