Chapter 8. Mixed Languages

We have seen how to use Gradle for projects with Java code. Gradle has support for other languages as well. In the last couple of years, other languages for JVM have emerged. In this chapter, we will take a look at Gradle's support for Groovy and Scala languages. Both languages are supported by JVM.

We will see how to apply the correct plugin and configuration to our Gradle build files to work with the different languages.

Gradle also supports C. The C plugin adds support to compile source files. JavaScript and Closure plugins are available as third-party plugins, which add support for these languages. We will not cover this support in this book. We will focus on the JVM languages-Groovy and Scala.

Using the Groovy plugin ...

Get Gradle Effective Implementations Guide - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.