Change to easy key binding
  1. Go Window > Preferences > General > Keys
  2. Command titled “Next Editor”, set binding CTL+Tab

Add remote project
  1. Remote System Explorer (RSE) is the solution.
  2. RSE may already be included in your current Eclipse installation.
  3. To check in Eclipse Indigo go to Window > Open Perspective > Other… and choose Remote System Explorer from the Open Perspective dialog to open the RSE perspective.
  • To create an SSH remote project from the RSE perspective in Eclipse:
    • Define a new connection and choose SSH Only from the Select Remote System Type screen in the New Connection dialog.
    • Enter the connection information then choose Finish.
    • Connect to the new host. (Assumes SSH keys are already setup.)
    • Once connected, drill down into the host's Sftp Files, choose a folder and select Create Remote Project from the item's context menu. (Wait as the remote project is created.)

Tricks to speedup Eclipse
  1. Edit the eclipse/eclipse.ini to increase the heap available to java: For instance, Change -Xms40m to -Xms256m (minimum heap) and -Xmx256m to -Xmx1024m (maximum heap).
  2. Add -Xverify:none to your eclipse.ini.
  3. Disable Eclipse validators: Go to Windows > Preferences > Validation and uncheck validators you don't need. (Classpath Dependency Validator may be needed.)
  4. Disable Plugins and start-up builds: Go to Windows > Preferences > General > Startup and Shutdown and turn off.
  5. Disable Eclipse PDT automatic build: Go to Windows > Preferences > General > Workspace and Turn off "Build automatically" and "Refresh using native hooks or polling".
  6. Disabling label decorations: Windows -> Preferences > General -> Appearance -> Label Decorations
  7. Go to Preferences -> Java -> Editor -> Content Assist -> Auto-Activation and decrease Auto activation delay from 200 to zero.
  8. Change the “auto activation triggers for Java” from "." to ".abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789()".

Eclipse Project Settings
  1. Java Build Path should like: {ProjetName}/src/main/java
  2. Add “Maven Managed Dependencies” library in build path eclipse: Go to Project Dir and run mvn eclipse:eclipse

Eclipse Corrupt or Crash
  1. Use ./eclipse -clean to cleanup the workspace.
  2. In worst case, delete all metadata relatred to project rm -rf ~/workspace/.metalog/.plugins/org.eclipse.core.resources/.snap/, but we need to be re-import all project.

Eclipse .project file
<?xml version="1.0" encoding="UTF-8"?>

Eclipse ignore "build directory"

CTRL+SHFT+R popup a window to find/open resource. But target/build directory included in this search result.

The solution is - from properties of target/build directory tick Derived.

Avoid "Resource is out of sync with the file system"

Go Preferences > General > Workspace and check "Refresh on access" and "Refresh using native hooks or polling"

Import Maven project in Eclipse
  1. Go to project directory, and run mvn eclipse:eclipse
  2. File > Import > General > Existing Projects into Workspace -> select project directory > Done

Unbound classpath variable: 'M2_REPO/…' error

Go Preferences > Java > Build Path > Classpath Variables > add M2_REPO and set path (/home/mmahmood/.m2/repository)

Compile java file automatically on save

Go Preferences > General > Workbench > check "Build automatically"

Eclipse Error: Virtual Machine Not Found

Problem: No Java virtual machine was found after searching the following locations: ~/Download/eclipse/jre/bin/java java in your current PATH
Solution: Create JRE directory symbolic link in Eclipse diretory.

sudo ln -s /usr/java/jre/ ~/Downloads/eclipse/

Open Java interface implementation

Just bind key (F3 is gr8)

Window-> Preferences-> General-> Keys and searching for "Open Implementation". (When: Editing Java Source)

JavaDoc shortcut
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License