Dear Sir/Madam,
Here is some part of our existing pom.xml.
<build>
  ...
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>2.0.2</version>
        <configuration>
          <source>1.5</source>
          <target>1.5</target>
        </configuration>
      </plugin>
    </plugins>
  ...
  </build>


However, we need to use 1.6 instead of 1.5 sometime. So we defined property
<properties>
<java.source.home>1.6</java.source.home>
<java.source.home>1.6</java.source.home>
</properties>
in each parent and child pom.xml.

So our pom.xml file for same portion above will be

<build>
  ...

<properties>
<java.source.home>1.6</java.source.home>
<java.target.home>1.6</java.target.home>
</properties>

    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>2.0.2</version>
        <configuration>
          <source>${java.source.home}</source>
          <target>${java.target.home}</target>
        </configuration>
      </plugin>
    </plugins>
  ...
  </build>
*************************************************************************************
My question is if we run a maven build : mvn clean install 
-Djava.source.home=1.5 -Djava.target.home=1.5
Will all ${java.source.home} and ${java.target.home} in each parent and child 
pom.xml be overrided with value 1.5? We have more than one level of 
parents/child.

Thanks.

Walt

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org

Reply via email to