I need a custom artifact setting and cannot figure out how to override the default value (due to the maven default life cycle). So my question is:
How to configure maven install plugin in my pom.xml so that it does not perform the default installation and only fulfill my custom installation file goals?
I tried without id and default-install and this did not help.
Update:
From the provided answer - this does not work for me (I see two installation attempts in the log).
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<executions>
<execution>
<id>default-install</id>
<phase>none</phase>
</execution>
</executions>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<version>2.3.1</version>
<executions>
<execution>
<id>install-jar-lib</id>
<goals>
<goal>install-file</goal>
</goals>
<phase>install</phase>
<configuration>
<file>${project.build.directory}/${project.build.finalName}.jar</file>
<generatePom>false</generatePom>
<pomFile>pom.xml</pomFile>
<packaging>jar</packaging>
<version>${unicorn.version}</version>
</configuration>
</execution>
</executions>
</plugin>
source
share