Gradle Build Tool Plugin Development
Note: Live training sessions are paused as we are working on self-paced training.
Live training sessions will resume next year.
Description
The Gradle Build Tool has a plugin framework that allows you to package reusable pieces of build logic that can be applied to different independent projects. You can author plugins to share new tasks, conventions as well as extend existing functionality.
By the end of this training you will learn how to develop, test and publish your own Gradle plugins.
Duration
3 hours
Audience
This class is designed for Gradle Build Tool users that want to author their own plugins.
Prerequisites
- Install the latest version of Gradle Build Tool along with at least Java 8
- Refer to the Java compatibility matrix to ensure appropriate Java version
- A good editor
- Recommended: IntelliJ community edition
- Significant Gradle Build Tool experience
- Knowledge of core concepts
- Authoring build files
- Kotlin DSL experience
- Familiar with Jacoco plugin
- Experience with Kotlin software development
- In this training we will code the plugin using the Kotlin language
Objectives
- Understand steps involved in authoring a standalone plugin
- Learn how to write meaningful tests to maintain plugins
- Hands-on exercises to reinforce learning
Course Outline
- Anatomy of a Gradle Plugin
- Setup for a new Plugin
- Developing the Plugin
- Define configuration using an Extension
- Initialize other Configuration
- Add a custom Task
- Publishing
- Next Steps