Reputation: 5037
I'm looking for some Gradle executor plugin for Maven (similar to Maven ant-run plugin).
Google did not help.
Is it possible that such plugin doesn't exist?
Upvotes: 30
Views: 16371
Reputation: 3002
I probably would use:
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<executions>
<execution>
<id>test</id>
<phase>test</phase>
<configuration>
<executable>./gradlew</executable>
<arguments>
<argument>test</argument>
<argument>-i</argument>
</arguments>
</configuration>
<goals>
<goal>exec</goal>
</goals>
</execution>
<execution>
<id>install</id>
<phase>install</phase>
<configuration>
<executable>./gradlew</executable>
<arguments>
<argument>install</argument>
</arguments>
</configuration>
<goals>
<goal>exec</goal>
</goals>
</execution>
</executions>
</plugin>
Because of the following reasons:
Failed to execute goal org.fortasoft:gradle-maven-plugin:1.0.8
Upvotes: 2
Reputation: 5037
I should try this: https://github.com/if6was9/gradle-maven-plugin
This is a maven plugin that makes it easy to invoke gradle from maven.
It is similar to the maven-antrun-plugin that allows ant to be invoked from maven.
Upvotes: 25