title: Exporting Maven properties from Ant code
body: <p>I've embedded the following code within my POM:</p>
  
  <pre><code>&lt;plugin name="test"&gt;
    &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;
      &lt;artifactId&gt;maven-antrun-plugin&lt;/artifactId&gt;
        &lt;executions&gt;
          &lt;execution&gt;
            &lt;phase&gt;validate&lt;/phase&gt;
              &lt;configuration&gt;
                &lt;tasks&gt;
                  &lt;pathconvert targetos="unix" property="project.build.directory.portable"&gt;
                    &lt;path location="${project.build.directory}"/&gt;
                  &lt;/pathconvert&gt;
                &lt;/tasks&gt;
              &lt;/configuration&gt;
            &lt;goals&gt;
          &lt;goal&gt;run&lt;/goal&gt;
        &lt;/goals&gt;
      &lt;/execution&gt;
    &lt;/executions&gt;
  &lt;/plugin&gt;
  </code></pre>
  
  <p>I then reference <code>${project.build.directory.portable}</code> from the <code>run project</code> action but it comes back as <code>null</code>. Executing <code>&lt;echo&gt;</code> within the Ant block shows the correct value. What am I doing wrong?</p>