Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to override default maven-install-plugin behavior?
    primarykey
    data
    text
    <p>I'm need of custom artifact installation and can't figure how to override the default one (from default maven lifecycle). So my question is:</p> <p>How to configure maven install plugin in my pom.xml so it doesn't do default install and executes just my custom install-file goals?</p> <p>I tried without id and with <a href="http://maven.apache.org/guides/mini/guide-default-execution-ids.html" rel="nofollow">default-install</a> id and it didn't help.</p> <p><strong>Update:</strong> From the provided answer - this does not work for me (I see two install attempts in log).</p> <pre><code>&lt;pluginManagement&gt; &lt;plugins&gt; &lt;plugin&gt; &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt; &lt;artifactId&gt;maven-install-plugin&lt;/artifactId&gt; &lt;executions&gt; &lt;execution&gt; &lt;id&gt;default-install&lt;/id&gt; &lt;phase&gt;none&lt;/phase&gt; &lt;/execution&gt; &lt;/executions&gt; &lt;/plugin&gt; &lt;/plugins&gt; &lt;/pluginManagement&gt; &lt;plugins&gt; &lt;plugin&gt; &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt; &lt;artifactId&gt;maven-install-plugin&lt;/artifactId&gt; &lt;version&gt;2.3.1&lt;/version&gt; &lt;executions&gt; &lt;execution&gt; &lt;id&gt;install-jar-lib&lt;/id&gt; &lt;goals&gt; &lt;goal&gt;install-file&lt;/goal&gt; &lt;/goals&gt; &lt;phase&gt;install&lt;/phase&gt; &lt;configuration&gt; &lt;file&gt;${project.build.directory}/${project.build.finalName}.jar&lt;/file&gt; &lt;generatePom&gt;false&lt;/generatePom&gt; &lt;pomFile&gt;pom.xml&lt;/pomFile&gt; &lt;packaging&gt;jar&lt;/packaging&gt; &lt;version&gt;${unicorn.version}&lt;/version&gt; &lt;/configuration&gt; &lt;/execution&gt; &lt;/executions&gt; &lt;/plugin&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload