Hi Filippo,
the create-kar goal doesn't work on the feature.xml, it just takes it to
create the kar file.
If you want to filter the feature.xml, you have to define the resources
and filtering, and call the resource plugin (as the packaing is pom):
<build>
<resources>
<resource>
<directory>${project.basedir}/src/main/feature</directory>
<includes>
<include>**/*</include>
</include>
<filtering>true</filtering>
</resource>
</resources>
<plugins>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<configuration>
<useDefaultDelimiters>false</useDefaultDelimiters>
<delimiters>
<delimiter>${*}</delimiter>
</delimiters>
</configuration>
<executions>
<execution>
<id>filter</id>
<phase>generate-resources</phase>
<goals>
<goal>resources</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
It makes sense to include it by default in the archetype, I will do that.
Regards
JB
On 05/11/2012 07:48 AM, Filippo Balicchia wrote:
yes
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>it.balyfix</groupId>
<artifactId>testkar</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>pom</packaging>
<build>
<plugins>
<plugin>
<groupId>org.apache.karaf.tooling</groupId>
<artifactId>features-maven-plugin</artifactId>
<version>2.2.7</version>
<executions>
<execution>
<id>create-kar</id>
<goals>
<goal>create-kar</goal>
</goals>
<configuration>
<featuresFile>${project.basedir}/src/main/feature/feature.xml</featuresFile>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
I create it from archetype.
Thanks
--Filippo
2012/5/11 Jean-Baptiste Onofré<[email protected]>:
Hi Filippo,
could you provide the pom used to create the kar ?
Regards
JB
On 05/10/2012 10:48 PM, Filippo Balicchia wrote:
Hi,
I create my simple project from archetype kar plugins version 2.7
After kar file was generated i see that feaure file was not filtered
and the version, fetures name ecc.ecc was not
replaced.
Is this a bug ? Or I need to replace manually the version ecc.ecc
Thank for help
--Filippo
--
Jean-Baptiste Onofré
[email protected]
http://blog.nanthrax.net
Talend - http://www.talend.com
--
Jean-Baptiste Onofré
[email protected]
http://blog.nanthrax.net
Talend - http://www.talend.com