Created
December 13, 2011 14:19
-
-
Save lalyos/1472269 to your computer and use it in GitHub Desktop.
maven bundle plugin configuration with macros
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<build> | |
<plugins> | |
<plugin> | |
<groupId>org.apache.felix</groupId> | |
<artifactId>maven-bundle-plugin</artifactId> | |
<version>2.3.5</version> | |
<extensions>true</extensions> | |
<configuration> | |
<instructions> | |
<EnvTest><![CDATA[ | |
JAVA_HOME="$<env;JAVA_HOME>" | |
]]> | |
</EnvTest> | |
<myversion>8.8.8</myversion> | |
<Import-Package><![CDATA[ | |
org.foo.package2;version="$<range;[==,=+);$<myversion>>" | |
]]> | |
</Import-Package> | |
<Message>Yeah Baby</Message> | |
<ReadFileMacroTest><![CDATA[ | |
textfile=$<cat;delme> | |
]]> | |
</ReadFileMacroTest> | |
<MacroTest><![CDATA[ | |
xmlfiles=$<lsa;target> | |
]]> | |
</MacroTest> | |
<Bundle-Activator>com.epam.osgi2.MyBundleActivator</Bundle-Activator> | |
</instructions> | |
</configuration> | |
</plugin> | |
</plugins> | |
</build> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
maven-bundle-plugin configuration
The documentation of maven-bundle-plugin regarding the BND specific configuration instruction wasn't clear enough.
So i was experimenting and tried to use some bnd macros. To generate the MANIFEST.MF you have to run the following:
The configuration above generates the following MANIFEST.MF: