Gradle-katas
Quick start
In the Cloud
On Your Local Machine
You need to have Java and Gradle installed to run these katas. Follow the intallation guides for each product:
- Java: adoptopenjdk.net
- Gradle: gradle.org
You can check your installation with the following command:
$ gradle -version
------------------------------------------------------------
Gradle 6.1
------------------------------------------------------------
...
To work through the katas, you need to clone this repository locally. For each exercise, you will then
- Go into the folder with the exrecise you want to work on
- Run the
setup.sh
script - Consult the README.md in that folder to get a description of the exercise
These katas are designed to run under Bash, so they should be straight forward to run on MacOS or most commont Linux distributions. For windows users, we recommend using Windows Subsystem for Linux (WSL).
Purpose of Gradle Katas
This repository is a collection of Gradle exercises. The concept is stolen without shame from Schauderhaft.de.
The exercises are designed for use when we are teaching Gradle courses. You should be able to use them as self-contained exercises that will allow you to keep your Gradle skills sharp.
Feel free to use these exercises, that's why they're public!
Suggested Learning Path
Setup
- gradle-wrapper-basics - Use the gradle wrapper to ensure that the correct gradle version is used.
Task creation
- task-creation - Add a simple task and execute it
- build-phases - Creating dependent tasks and ordered execution
Properties
- configuring-properties - Different ways of passing properties to the build
- checking-properties - Verifying and using passed properties
Task Flow
- task-execution-order - Instructing your tasks to run in certain order
- task-dependencies - Creating a DAG (directed acyclic graph) out of your tasks
Skipping task
- incremental-tasks - Defining build-input and output
- skipping-execution - Conditional execution of tasks
Task types
- built-in-task-types - Experiment with a variety of built-in types
- custom-task-types - Defining custom re-usable types.
Plugin
- applying-plugins - Looking into available plugins
Task rules and dynamic tasks
- task-rules - Dynamic task content
- dynamic-task-creation
Artifact handling
- publish-artifact - How to share your artifact. Group, name and version practices.
- resolve-artifact - Compile code using the artifact as a dependency
Extras