Training

  • Meaningful Knowledge Transfer
  • Clarify Difficult Requirement Approaches
  • Hands-on Learning

In-Depth Training

Our intensive courses equip your development team with advanced know-how of Gradle-based project automation—all through small, informative hands-on classes.

Overview

Join us for three days of intensive Gradle instruction from Tim Berglund, co-author of Building and Testing with Gradle and official Gradleware trainer for North America. The class begins with Groovy fundamentals, then moves quickly into thorough coverage of Gradle topics like tasks, standard Gradle plugins, file manipulation, Gradle's logging support, IDE integration, multiproject builds, Ant integration, Maven integration, custom tasks, and even Gradle plugins.

You'll spend around half of your time actually coding in Gradle, and the other half talking with the instructor and learning directly from his live coding exercises. This class can take you from complete newcomer status to Gradle competence, or from passing familiarity to Gradle expertise. Don't miss it.

Course Prerequisites

This course assumes a good understanding of the Java language. Some code is initially easier to understand if you also have a basic understanding of the Groovy language. But due to Groovy's similarity to Java, Groovy is not a prerequisite. There will be a very short introduction to Groovy at the beginning of the course.

Course Program

Day 1 Day 2 Day 3

Groovy Basics

  • Using the Groovy Console
  • Syntax basics
  • Dynamic typing
  • Strings
  • Closures
  • Collections and iterators
  • Properties
  • File I/O

Gradle Introduction

  • Imperative build styles
  • Declarative build styles
  • Convention over configuration
  • Modeling by convention
  • The dependency graph

Tasks

  • Declaring a task
  • Task action
  • Task configuration
  • Gradle lifecycle phases
  • Task properties
  • Task types

Plugins

  • The Gradle plugin model
  • Review of core plugins

The Java Plugin

  • A simple Java build
  • The tasks of the Java plugin
  • Testing Java
  • Exploring SourceSets
  • Customizing a Java build
  • Using JavaExec
  • Dynamic task creation

Dependency Management

  • Declaring dependencies
  • Configurations
  • Resolving to Maven Central
  • Resolving to flat directories

File Manipulation

  • file(), files(), and fileTree()
  • The FileCollection interface
  • Accessing ZIP files
  • The Copy task
  • CopySpecs
  • Filtering and modifying files

Logging

  • SLF4J
  • Redirecting System.out.println()
  • Logging levels

IDE Integration

  • The Eclipse Gradle plugin
  • Using the SpringSource Tool Suite with Gradle
  • The Eclipse IDEA plugin
  • Using IntelliJ IDEA with Gradle

Multiproject Builds

  • Gradle’s build model and the multiproject environment
  • Declaring a multiproject build
  • The multiproject API
  • A subproject without a build file

Ant Integration

  • Comparing paradigms
  • Comparing vocabularies
  • Gradle’s AntBuilder
  • Importing an Ant Build
  • Extending Ant targets as Gradle tasks
  • Modifying Ant properties in a Gradle build

Maven Integration

  • Exporting with the Gradle Maven Plugin
  • Importing with the GradleM2Metadata Plugin
  • Converting with Maven2Gradle

Custom Tasks

  • Factor imperative code out of builds
  • Annotating task actions
  • Annotating file inputs and outputs
  • Build file, buildSrc, external JAR locations

Custom Plugins

  • Plugin philosophy: extending the DSL
  • The Plugin API
  • Plugin Conventions
  • Creating custom tasks
  • Creating domain objects
  • Packaging plugins
Talk to us about training

Successful Gradle Users