Maintaining a common set of Eclipse preferences

Solution 1:

You could of course export/import those settings.

The other approach is to enable project specific settings for some settings.

http://www.peterfriese.de/wp-content/downloads/images/formatter_project_specific_settings.jpg

We have a very small Git repository with those kind of files:

http://www.mkyong.com/wp-content/uploads/2009/01/wicket-examples-7.jpg

  • .settings/org.eclipse.jdt.core.prefs (compiler problem settings and formatter rules)
  • .settings/org.eclipse.jdt.ui.pref (cleanup rules, common code templates)

The common settings are just copied/merged in each projects .settings directory, ensuring common rules amongst all projects, whatever the workspace.

Solution 2:

You could also try Workspace Mechanic. It works perfect for this. http://code.google.com/a/eclipselabs.org/p/workspacemechanic/

Solution 3:

Eclipse now ships with a tool called Oomph Setup. This tool can be used to record the preference changes that happen in your workspace, synchronize those preferences across multiple machines using an online service, and apply the preferences to both new and existing workspaces.

"Oomph" is actually a broader set of tools and low-level frameworks that are used throughout the Eclipse installation process, and it provides for very powerful automation possibilities, so the documentation is sometimes hard to follow for an end user who's just interested in simple preference synchronization. Here are a collection of links about Oomph Setup that I found helpful:

  • Oomph: A Matter of Preference -- Blog post providing overview of preference tool
  • Oomph Setup Documentation -- Official documentation
  • Automating Project-specific Eclipse Setups with Oomph -- Walks through how to set up Eclipse to have default settings for new workspaces and automatically update the settings for existing workspaces