A great high-level introduction to a build tool on the rise.
By Benjamin Muschko.
Manning Publications, 2014
15 chapters packed with instructive, to-the-point and useful material. Good selection of material. Best practice of Gradle is reviewed continously.
Gradle is viewed as an improvement over the older build tools Ant and Maven.
The single biggest way in which Gradle diverges from the older tools is that build scripts are written as code, not XML. For most build script writers/maintainers, this will come as a welcome change. After all, the older tools evolved in a time when C++ make scripts was the mainstream, and there was no obvious way to create a tool such as Gradle – a dynamic JVM language like Groovy had not appeared yet.
Gradle has also learned from the evolution of these older tools, as it has taken the concept of ‘Convention over configuration’ from Maven, and attempts to remedy the drawback of Maven, in making it easier to configure non-traditional settings.
The writing style is very much to-the-point, readable and instructive.
Working with tasks, projects and properties, Gradle wrapper, Multi-module projects, build lifecycle hooks, dependency management, test support, extending Gradle with script plugins, custom tasks and plugins, integration with and migration from Ant/Maven.
Part 3 covers some specialised topics: IDE support, Gradle tooling API, polyglot projects (including integration with Grunt), code coverage, static analysis, continuous integration, artifact assembly and publishing, infrastructure provisioning and deployment.