Cover by Hubert Klein Ikkink

Safari, the world’s most comprehensive technology and business learning platform.

Find the exact information you need to solve a problem on the fly, or go deeper to master the technologies and skills you need to succeed

Start Free Trial

No credit card required

O'Reilly logo

Chapter 3. Working with Gradle Build Scripts

A Gradle script is a program. We use a Groovy DSL to express our build logic. Gradle has several useful built-in methods for handling files and directories, because we often deal with files and directories in our build logic.

In this chapter we will learn how we can use Gradle's features to work with files and directories. Also, we will take a look at how we can set properties in a Gradle build and use Gradle's logging framework. Finally, we see will how we can use the Gradle wrapper task to distribute a configurable Gradle with our build scripts.

Working with files

It is very common in a build script that we have to work with files and directories. For example, when we need to copy a file from one directory ...

Find the exact information you need to solve a problem on the fly, or go deeper to master the technologies and skills you need to succeed

Start Free Trial

No credit card required