Eclipse Diff Util For Creating Dropins Folder Contents

Personally I prefer the drop-ins folder for extending my Eclipse with new plug-ins and features. Having all your favorite extensions in one place separated from the default Eclipse contents is great. When it comes to setting up a new Eclipse with the same plug-ins and features it becomes as simple as zipping a drop-ins folder and unzip it in a brand new Eclipse installation. There are no update site imports and long running update installations required. This even works perfectly across different platforms.

But when it comes to adding new features or plug-ins to your drop-ins folder it takes quiet some effort. First, you usually need to install a new extension via an update site. Then you need to identify the plug-ins and features that have been added to your Eclipse and last but not least copy or move these to your drop-ins folder.

Now, I’ve spend some of my spare time to create a tool that compares two Eclipse folders:
The Eclipse Installations Diff Util in action

Basically, the application is made up of three tree viewers. On the left side you choose a folder containing an Eclipse product without the plug-ins and features you wish to extract. On the right side you choose a folder containing an Eclipse product that has features and plug-ins installed, that you want to isolate. Once both, the left and right, folders are scanned the Eclipse Installations Diff Util will automatically compare both and calculate the difference that will be shown in the center tree viewer. Set a target folder above the center tree viewer where the extensions should be extracted to. A valid target folder will enable the center tree viewer so you can select the elements you want to extract.

A use case would be: You have an Eclipse installation and want to add a new feature that you actually want to put in the drop-ins folder, but the feature is only available via update site.
The steps that will get you there with the Eclipse Installations Diff Util are

  1. Close and ZIP your Eclipse. Lets say the Eclipse folder was “eclipse”, so we call the zip eclipse-plain.zip.
  2. Start Eclipse.
  3. Add new update site.
  4. Install new feature from update site.
  5. Close Eclipse.
  6. Rename eclipse folder to “eclipse-extended”.
  7. Unzip eclipse-plain.zip.
  8. Start the Eclipse Installation Diff Util.
  9. As plain Eclipse choose your “eclipse” folder.
  10. As extended Eclipse choose your “eclipse-extended” folder.
  11. In the top center set your “eclipse/dropins” folder as target.
  12. In the center tree viewer select the “features” and “plugins” folder.
  13. Click “Extract Missing Extensions”.

Extracting missing extensions to a target folder

The Eclipse Installations Diff Util will copy all selected folders and files with their contents to the target folder and notifies when finished.

Extraction finished

Another use case might be: You have a fully blown Eclipse with lots of custom features and plug-ins and need to setup a new Eclipse with the same features. In that case you need the clean ZIP that Eclipse was based on, e.g. by downloading it from eclipse.org. That Eclipse is the plain Eclipse, the other one the extended, though. Now you can easily extract every plug-in and feature that was added to turn the plain Eclipse to the fully blown one.

So, here’s the Eclipse Installations Diff Util for download (~4.5 MB; you’ll need Java >= 1.5 to run it):

Sources are available at github: https://github.com/rowlo/eclipsediffutil

5 comments to Eclipse Diff Util For Creating Dropins Folder Contents

  • Jimmy Ljungberg

    Thanks for creating this. It made it much easier for me to setup Eclipse in our environment that has no access to internet.

  • [...] the dropins folder. As it can be quite a pain to create the contents for that folder I wrote an Eclipse Diff Util which I showed in the live demo. At the beginning I was asking who knew the dropins folder and [...]

  • tonito

    Hi,
    can you explain in more details your step 8.Start the Eclipse Installation Diff Util. ? I would like to use DiffEclipse_win64.jar (Windows)

    • robert

      Hi,
      to start the Eclipse Diff Util in Windows it should be sufficient to double click the jar file in Windows Explorer. If that doesn’t work, make sure the folder containing java.exe is added to your PATH environment variable.
      As a last option you can also open up a command line and enter: java -jar DiffEclipse_win64.jar
      Rob

Leave a Reply

  

  

  

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>