karaf-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christoph Gritschenberger <christoph.gritschenber...@gmail.com>
Subject Re: Kar features.xml file is not filtered
Date Fri, 19 Oct 2012 09:41:12 GMT
You need to enable resource-filtering in your maven-build. You can set
this up in your pom.xml like this:



kind regards,

On 19/10/12 11:16, Giacomo Coletta wrote:
> Hi,
> i started using the KARs archives, and creates a few KARS using the KAR
> archetype.
> one problem I encountered is that the features.xml file included in the kar
> in the generated maven project doesn't seem to be maven filtered by default.
> I would like it to be filtered for managing the included karaf features and
> bundles versions using maven properties like in the following example:
> <features name="myfeatures-repo" version="${myfeatures-repo.version}">
>     <feature name="myfeature" version="${myfeature.version}">
>           <bundle>
> mvn:mybundle.groupId/mybundle.ArtifactId/${mybundle.version}</bundle>
>     </feature>
> </features>
> i was able to do this while including the features in an assembly using the
> add-features-to-repo goal of the features-maven-plugin (features.xml was
> filtered by default)
> I tried to do the same with kars, but I was not able to get to this result
> quickly.
> May be this is related to the fact that in the features-maven-pluging the
> create-kar goal is tied to the package phase, while
> the add-features-to-repo was in the compile phase.
> Does anybody know a standard or easy way to have the features.xml file
> maven filtered in KARs ?
> Many Thanks
> Giacomo

View raw message