TomDmitriev/gradle-bundle-plugin — pull request #18 by gamerson (2014-08-27 06:02:06+00:00)
Title: Support for gradle-2.0 build

With gradle 2.0 there were several changes necessary.

1. Add a unit test for assertion that the jar task should only have one action, namely the BundleGenerator, so you can see that here: https://github.com/gamerson/gradle-bundle-plugin/commit/a4650f6d562a0ad65e5c89be53280855a5d4d50e

If you merge just this one and then re-run the integration tests with gradle-1.x it should pass.

2. Needed to make spock dependency conditional on the gradle version

3. For gradle-2.0 the old way of setting up the actions will not work (not for sure why, maybe actions property is immutable?), but I found a new API that works in both gradle-1.x and 2.0, see here: https://github.com/gamerson/gradle-bundle-plugin/commit/18b4a7d814f1a3b180abb93d7240918819d0d73c

4. When I was trying to test this I was having trouble with getting the integTests to run and that is because the output of the gradle install task (in both 1.2 and 2.0) is the following coordinates `org.dm.gradle:gradle-bundle-plugin` but the `build.test` integTest build file points to `org.dm.gradle:bundle` which is not produced by the build locally.

This point there seems to be some confusion because the existing published artifacts use the `ord.dm.gradle:bundle` coordinates, but `gradle install` sets the artifact name at `gradle-bundle-plugin`. So I'm not sure which way you would rather do it, that is up to you, but IMHO `gradle-bundle-plugin` is more standard.

Thanks!