title: Execute Maven plugin goal on child modules, but not on parent
body: <p>In a multi-module project, how can you specify that you want to execute a plugin goal in all the child-modules, but not on the parent project? There is <code>&lt;pluginManagement&gt;</code>, but that only defines the configuration for the execution -- the child modules would still need to reference the plugin to get the goal executed:</p>
  
  <blockquote>
    <p>[...] However, this only configures plugins that are actually referenced within the plugins element in the children. <em>(<a href="http://maven.apache.org/pom.html#Plugin_Management" rel="noreferrer">POM Reference</a>)</em></p>
  </blockquote>
  
  <p>Any other way to achieve this?</p>
  
  <p><strong>UPDATE:</strong> I've tried this according to Pascal's advice:</p>
  
  <pre class="lang-xml prettyprint-override"><code>&lt;!-- ... --&gt;
  &lt;packaging&gt;pom&lt;/packaging&gt;
  &lt;modules&gt;
    &lt;module&gt;child&lt;/module&gt;
  &lt;/modules&gt;
  
  &lt;build&gt;
    &lt;plugins&gt;
      &lt;plugin&gt;
        &lt;artifactId&gt;maven-jar-plugin&lt;/artifactId&gt;
        &lt;executions&gt;
          &lt;execution&gt;
          &lt;phase&gt;integration-test&lt;/phase&gt;
          &lt;goals&gt;
            &lt;goal&gt;jar&lt;/goal&gt;
          &lt;/goals&gt;
          &lt;/execution&gt;
        &lt;/executions&gt;
      &lt;/plugin&gt;
    &lt;/plugins&gt;
  &lt;/build&gt;
  &lt;!-- ... --&gt;
  </code></pre>
  
  <p>This will still generate a .jar for the parent project, even though the <code>jar</code> goal is bound to the <code>integration-test</code> phase.</p>