Maven, one of the another build tool, which got most popularity after Ant and it also came with dependency management solution to the problem that the users were facing in Ant. The first problem in Ant was imperative programing where user has to write lots of boiler plate code. Another problem was dependency management. Ant does not have any in-built dependency management solution (Ant later integrated with Ivy for dependency management). A user has to write each and every JAR file path in the build file that it needs to download, and in case of transitive dependencies, it is too complex for the user to identify each and every dependent JAR and mention the JAR name in the build file. Also, in case of version conflicts, it consumes lots of a developer's efforts. Maven came with the declarative programing model and in-built dependency management solution. Gradle is also built on the top of these principles; thus, migrating from Maven to Gradle seems very comfortable...
Overview of this book
Gradle is an advanced and modern build automation tool. It inherits the best elements of the past generation of build tools, but it also differs and innovates to bring terseness, elegance, simplicity, and the flexibility to build. Right from installing Gradle and writing your first build file to creating a fully-fledged multi-module project build, this book will guide you through its topics in a step-by-step fashion. You will get your hands dirty with a simple Java project built with Gradle and go on to build web applications that are run with Jetty or Tomcat. We take a unique approach towards explaining the DSL using the Gradle API, which makes the DSL more accessible and intuitive. All in all, this book is a concise guide to help you decipher the Gradle build files, covering the essential topics that are most useful in real-world projects. With every chapter, you will learn a new topic and be able to readily implement your build files.
Table of Contents (17 chapters)
About the Authors
About the Reviewers
Running Your First Gradle Task
Building Java Projects
Building a Web Application
Demystifying Build Scripts
The Real-world Project with Gradle
Testing and Reporting with Gradle
Organizing Build Logic and Plugins