Hello, I have a .NET multi module project. I'm using the npanday plugin to
build the project and it seems to be working ok. However I can't seem to
reference maven properties from within my pom.xml file like I can with java
projects. Can anybody tell me if it's possible to reference maven properties
like ${project.version} or ${project.groupId} from within a pom.xml when using
NPanday? It doesn't seem to work for me. I've tried the following variants:
${version}, ${pom.version}, and ${project.version}. None of them seem to work
correctly. It seems to reference the file in the /target folder correctly
however it doesn't actually copy the library to the /target folder from the
local or host repositories before the compile phase. Therefore it fails saying
that it can't find the file. Attached is something similar to my pom.xml
Dashboard.Client depends on Dashboard.Common, both are set to the same version
'1.0-SNAPSHOT '. I want to reference groupId and version info in
Dashboard.Client pom.xml with the ${project.groupId} and ${project.version}
properties.
Any help would be appreciated. Thanks.
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.acme</groupId>
<artifactId>Dashboard.Client</artifactId>
<name>Dashboard.Client</name>
<version>1.0-SNAPSHOT</version>
<packaging>library</packaging>
<dependency>
<groupId>${groupId}</groupId>
<artifactId>Dashboard.Common</artifactId>
<version>${version}</version>
<type>library</type>
</dependency>
<dependencies>
<dependency>
<groupId>NUnit</groupId>
<artifactId>NUnit.Framework</artifactId>
<version>2.5.8</version>
<type>library</type>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<sourceDirectory>src/main/csharp</sourceDirectory>
<testSourceDirectory>src/test/csharp</testSourceDirectory>
<plugins>
<plugin>
<groupId>npanday.plugin</groupId>
<artifactId>maven-compile-plugin</artifactId>
<extensions>true</extensions>
</plugin>
</plugins>
</build>
</project>