Gradle Training Workshop


(Miko) #1

Originally published at: https://gradle.org/training/gradle-training-workshop-3/

Duration


One Day (two half day virtual instructor led sessions + Q&A)

Description

The Gradle Virtual Training Workshop is a fast paced virtual introduction to the Gradle build system. In this two-part hands-on Gradle workshop you learn about topics such as: fundamental Gradle concepts, getting started with Gradle, authoring build scripts, using tasks and plugins, building Java projects, automated testing, and multi-project builds. About half of the time is hands on and spent on practical exercises. Participants will spend a significant portion of the class with their hands on the keyboard, learning by doing, working through lab exercises designed to build on the presented material.The class will be delivered by a Gradle Core Developer which gives you access to the deepest Gradle knowledge available.

Objectives

Upon completion of this course you will …
  • Learn the important parts of Gradle to get your build up and running
  • Learn to go beyond using Gradle builds
  • Look at some new features of Gradle
  • Get to ask questions from a Gradle core developer!

Prerequisites

This class has something for every level of Gradle user.

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.

Course Outline

Part 1

Gradle Introduction
  • About the Gradle project
  • Gradle documentation
  • Gradle resources
  • Lab 1: Gradle setup and installation
  • Lab 2: Quickstart
Gradle Build Scripts
  • Gradle Build Daemon
  • Lab 3: Daemon setup
Tasks
  • Task Actions
  • Executing Tasks
  • Abbreviated task name executions
  • Task types and API
  • Implementing Task types
  • Lab 4: Custom Tasks
Build Lifecycle
  • Lab 5: Build Lifecycle
Gradle Plugins
  • Typical plugin functions
  • Plugin packaging
  • Script plugins
  • Remote script plugins
  • Binary plugins
  • Declaring plugin IDs
  • Non project plugins
  • Standard Gradle plugins
  • Plugin stacks
  • Plugins applying plugins
  • Extensions
  • Lab 6: Applying plugins

Part 2

Incremental Build
  • Inputs and Outputs
  • Input/Output Annotations
  • Input and Output API
  • Incremental Builds
  • Inferred task dependencies
  • Lab 7: Task Input and Output
Dependency Management
  • Dependencies and Java Plugin
  • Working with Dependencies
  • Lab 8: Dependencies
Transitive Dependencies
  • Dependency resolution strategies
  • Publishing Artifacts
  • Repositories
  • Uploading artifacts
  • Uploading to Maven repositories
  • Install to Maven local
  • Customizing the POM
  • Lab 9: Maven uploading
Organizing Build Logic
  • Best practices
  • Build scripts
  • buildsrc
  • Jar
  • Build script plugin
  • Lab 10: Organizing Build Logic
Latest Gradle Features
  • Gradle Wrapper
  • Lab 11: Gradle Wrapper

(René Groeschke) #2