Pax Eclipse Plugin

An Eclipse plugin for developing projects build by mvn with maven-bundle-plugin and maven-pax-plugin.

Features

Up-to-date check for META-INF/MANIFEST.MF

META-INF/MANIFEST.MF file used by Eclipse PDE is generated by maven and must not be edited manually.
But, after each modification of pom.xml and/or osgi.bundle, META-INF/MANIFEST.MF should be generated again.

Pax Eclipse plugin checks modification dates for pom.xml, osgi.bundle and META-INF/MANIFEST.MF files - in case when META-INF/MANIFEST.MF is older than others, the plugin reports problem.
Then you should run maven (from Eclipse or from command line, but remember about Refresh in Eclipse) and problem should disappear.

Copying of resources

Pax Eclipse plugin copies all created or modified files form src/main/resources/META-INF/ to META-INF/.
Sou you can easy edit for example files for spring-osgi in src/main/resources/META-INF/spring/, and after you save changes, plugin copies files to META-INF/spring/ and you can immediately run Osgi Framework.

Setting derived flag for resources in META-INF

Pax Eclipse plugin sets derived flag for directory META-INF and all files copied to it. The derived flag means, that resource is generated and Eclipse warns, when you want to edit such resource and also skips it while adding to version control.

Installation

Because of https issues, first checkout update site from svn (it's only ~200k):

   svn co https://scm.ops4j.org/repos/ops4j/laboratory/users/damian.golda/updatesite   pax-eclipse-plugin-updatesite

Then use standard Eclipse Updater:
Help, Software Updates, Find and Install, Search for new features to install, New local site - select your folder (for example c:\path\pax-eclipse-plugin-updatesite)

Usage

Usage is very easy - you only should add to project Pax OSGi nature:
Package Explorer, select project or projects, right buton, Add Pax OSGi nature.

Modification

Plugin modifies:

  • .project - adds nature and builder
  • META-INF and nested - sets derived flag
  • copies src/main/resources/META-INF/ to META-INF/

Source code

https://scm.ops4j.org/repos/ops4j/laboratory/users/damian.golda/

License

Apache Licence 2.0 http://www.apache.org/licenses/LICENSE-2.0