Eclipse Can Do That!?

There’s a good reason Eclipse has remained the most popular Java IDE for all these years. There’s so much cool stuff you get in Eclipse, and even more when you add plugins! Take a look at some favorite Eclipse tips. Have a favorite that didn’t make the list? Let us know!

01

Java Debug Return Values

If you’ve hated adding dummy variables just to get a look at what a method returns while debugging, you’ll love this. When you hit a method exit breakpoint, or step through a method, the method result (via return or throw) will be shown in the Variables view.

Z

Requires:

02

Test Source Folders

A source folder can be configured as one that “contains test sources”. This allows you to control how the folder is displayed, whether test code is visible in your primary code or by other projects, and even have separate test-only dependencies.

Z

Requires:

03

Vue.js Development

Vue has become a favorite framework for building websites and single-page applications, and you can have a great development experience in Eclipse when using Vue. Powerful IntelliSense, quick navigation, smart validation and linting, new project wizards and integrated debugging are all available.

Z

Requires:

04

Java 10

Java 10 introduced var support. Hover over a local variable declared with var to instantly see the actual type. Use the quick fix action to convert the declaration to use the actual type, or vice-versa.

05

Git Revision History

Do you need to know exactly how a file in a Git repository has changed? Use the History view, or display revision information directly in the editor, colored by author/date as required.

Z

Requires:

06

Dark Theme

For a truly dark Eclipse experience, across all operating systems, try either the Darkest Dark or Deep Black theme—both included with the DevStyle plugin. If you’re not a dark fan, there is a collection of fresh, light themes too. Dark or light, all themes have unique, customizable icon sets, as well as a number of editor color sets to choose from.

Z

Requires:

07

Remote System Explorer

If you need to deal with remote systems, use the Remote System Explorer. It supports SSH, FTP, Telnet, and several other OS-specific protocols. Manipulate files, and even launch a remote shell, without leaving the IDE.

08

Live Preview

Frontend development goes much faster when you can immediately see changes as you update code. With Live Preview, you see a preview of your application right next to your code editor, and for some projects, changes appear as you type without requiring a save. You can pass URL parameters to easily test your application, configure the preview layout to your liking, and even detach the browser.

Z

Requires:

09

Launch Groups

Use a Launch Group to launch multiple configurations with a single click. You can set up each configuration to simply launch sequentially, wait for the previous launch to terminate, emit specific output, etc., before launching.

10

Trigger/Watch Points

Don’t waste time stepping through code when you don’t have to. Create a Trigger Point to skip breakpoints, until the trigger point itself is hit. Watch points can now have conditions, ensuring that execution is suspended only when the specified condition is met.

11

NPM IntelliSense

Use IntelliSense in your package.json files to get recommendations for Node module names and versions. So if you can’t remember a module name, or want to upgrade your modules, this capability makes it super convenient.

Z

Requires:

12

Smarter IntelliSense

With Code Recommenders, content assist suggestions are ordered based on what other developers have called in a similar context—no more alphabetical suggestions to sift through! There’s a lot more that Code Recommenders can do—including  advanced templatized snippets for most file types using the Snipmatch snippet engine.

13

Debug Console

The Debug Console can be a significant debugging asset. Use this to inspect, or even modify values during your debugging session. If you’re debugging Java, these capabilities are present in the Debug Shell view (a.k.a. Display view prior to Eclipse Photon).

14

Static Analysis

It’s no secret that running your code through a static analyzer can vastly improve its quality. Spotbugs (formerly Findbugs), Checkstyle, and PMD, are well known static analyzers for Java, all of which have Eclipse integrations.

With these plugins, you can see potential problems reported in the IDE itself, allowing you to navigate to, and correct issues easily—some can even be corrected with Quick Fixes!

15

Emacs and Vi Power

Is the potential loss of key bindings and commands the only thing stopping you from moving from Emacs or Vi to a full blown IDE like Eclipse?

Use the Emacs+ or Vrapper plugins to give you access to these same powerful capabilities in any Eclipse editor. And we’re not just talking about key bindings, commands work as well.

Z

Requires:

16

Preview on Hover

You don’t need to jump between source files to see how a method is implemented, or a field defined. Press Shift (Java) or Ctrl (CodeMix supported languages) when hovering over your code, to peek at the definition without leaving your current editing context!

17

Advanced Source Lookup & Decompilers

Even if you don’t have the source attached while debugging a Java application, the JDT’s “Advanced Source Lookup”, is capable of finding and attaching the source for you—even downloading it from remote repositories if required.

If the JDT can’t find it, there’s always the Enhanced Class Decompiler, which can use a Java decompilation engine of your choice to seamlessly deliver source you can step through.

18

CSS Preview

Can’t remember what the difference is between > and ~ when working with CSS selectors? Fret not, hover over a selector to see an instant preview of the elements it would target—very handy when dealing with complex selectors and advanced CSS syntax!

Z

Requires:

19

Emmet Commands

Emmet is fantastic for quick abbreviation expansion, but did you know that is just a snippet of what Emmet commands can do? Use Emmet to create lists, update image sizes, do some math, and much more!

Z

Requires:

20

Quick Search

When you’re trying to find a simple string within files in your workspace, the Quick Search (Ctrl/Cmd+Shift+Alt + L)  is much faster, and easier to use than the File Search dialog. You can limit the search to specific file types, but the best bit is the preview of the section of the file with the matched text.

Z

Requires:

21

Chain Template Proposals

The JDT’s Chain Template Proposals will traverse reachable fields, local variables and methods, to produce a call chain whose return type is compatible with the expected type.

How do you get a Document from DocumentBuilderFactory? Let the chain template proposal figure that out for you. Enable them at Preferences > Java > Editor > Content Assist > Advanced.

 

Z

Requires:

22

Explorer Font Size

Have you found the Project/Package Explorer font sizes to be too small? With the latest release of DevStyle, you can make them as large as you desire!

 

Z

Requires:

23

Pair Programming

Need to work with your remote team? You can start a pair programming, or even a mob programming session with CodeTogether. Everyone can contribute, with full IDE-like capabilities available to all who join – beats screen sharing!

Z

Requires:

Help Us Improve This List of Eclipse Tips!

With so many cool ways to use Eclipse, we’re sure our list of Eclipse tips is incomplete. If you have a tip you’d like to see added, we’d love to hear from you. Send us an email! ideas@eclipsecandothat.com