Sample of a mavenized eclipse RCP plugin with eclipse IDE support
This project demonstrates how to develop an eclipse Rich Client Platform plugin using Maven for build and dependency management, without giving up eclipse IDE support and without using Tycho or m2e.
Run mvn install
. The resulting artifact is an eclipse plugin.
-
Generate Eclipse metadata:
mvn clean package eclipse:eclipse -Declipse.pde install
-
Import the projects into Eclipse:
File->Import->Existing Projects into Workspace
-
Run the
eclipse-plugin
project:Run As->Eclipse Application
-
Open the view:
Window->Show View->Other->Test Category->Test View
-
eclipse-plugin
This project was generated using the
Plug-in with a view
eclipse template. It has been mavenized and modified to introduce some trivial dependencies. -
eclipse-plugin-utils
Used by
eclipse-plugin
to demonstrate a dependency on another project in the same workspace.
-
Maven vs. eclipse resource convention
Maven conventionally wants resources in
src/main/resources
while eclipse wants all of its resources in the root. The solution was to place resources in the root and include them using Maven (see eclipse-plugin/pom.xml). -
Eclipse Maven repository
The latest maven repository in central dates back to eclipse version 3.3. The m4e tool can be used to generate maven repositories from the latest eclipse, but for the sake of simplicity I am using version 3.3.
Apache Felix maven-bundle-plugin
article on eclipse integration:
Apache UIMA uses maven-bundle-plugin
: