I want to run some code after the eclipse goal of the eclipse plugin (eclipse:eclipse) runs.
The documentation of the eclipse plugin says that the generate-resources phase is execute prior to the eclipse goal, but it doesn’t mention any phase that is executed after.
I wanted to include the code with the gmaven-plugin but I can’t find the right configuration:
<execution>
<id>delete_generated_sources_from_cp</id>
<phase>generate-resources</phase>
<goals>
<goal>execute</goal>
</goals>
<configuration>
<providerSelection>1.7</providerSelection>
<source>
modifyClasspath.groovy
</source>
</configuration>
</execution>
Simply add the plugin you want to execute to your project. If you add an execution of the plugin to the phase
process-resourcesit will execute after the eclipse plugin if you runmvn process-resources(or any phase after process-resources)You could also invoke them directly:
mvn eclipse:eclipse otherplugin:goal