Skip to content

Instantly share code, notes, and snippets.

@chenrui333
Last active October 21, 2015 01:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save chenrui333/4a112da8d636c96fd218 to your computer and use it in GitHub Desktop.
Save chenrui333/4a112da8d636c96fd218 to your computer and use it in GitHub Desktop.
upgrade GMavenPlus dependencies
1. dependency part about Groovy and Spock
2. plugin part about gmavenplus and source plugin (compiler plugin not included)
<dependency>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy-all</artifactId>
<version>2.4.4</version>
</dependency>
<dependency>
<groupId>org.spockframework</groupId>
<artifactId>spock-core</artifactId>
<version>1.0-groovy-2.4</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.spockframework</groupId>
<artifactId>spock-spring</artifactId>
<version>1.0-groovy-2.4</version>
<scope>test</scope>
</dependency>
<!--FIXME: GMaven plugin is no longer supported, GMavenPlus is the alternative-->
<!--latest GMaven is gmaven-runtime-2.0 only support for Groovy 2.0.x.-->
<plugin>
<groupId>org.codehaus.gmavenplus</groupId>
<artifactId>gmavenplus-plugin</artifactId>
<version>1.5</version>
<executions>
<execution>
<goals>
<!--<goal>addSources</goal>-->
<!--<goal>addTestSources</goal>-->
<!--<goal>generateStubs</goal>-->
<goal>compile</goal>
<!--<goal>testGenerateStubs</goal>-->
<goal>testCompile</goal>
<!--<goal>removeStubs</goal>-->
<!--<goal>removeTestStubs</goal>-->
</goals>
</execution>
</executions>
</plugin>
<plugin>
<!-- if including source jars, use the no-fork goals
otherwise both the Groovy sources and Java stub sources
will get included in your jar -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<!-- source plugin \> = 2.1 is required to use the no-fork goals -->
<version>2.4</version>
<executions>
<execution>
<id>attach-sources</id>
<goals>
<goal>jar-no-fork</goal>
<goal>test-jar-no-fork</goal>
</goals>
</execution>
</executions>
</plugin>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment