Skip to content

Rework Gradle to use Kotlin DSL + Total build file cleanup

Chris Lemaire requested to merge rework-gradle-build into development

The new build.gradle.kts file was built carefully with Gradle's recommendations in mind. In this MR all configurations from the old gradle.build are copied over to the new gradle.build.kts piece by piece.

This commit reorders the configuration of tasks and plugins and the declarations of plugins and dependencies. This is to make for a more logically read build script with clear markers of where to put what. Additionally, plugins are now applied using the modern way of declaring plugins.

Gradle.build.kts is the Kotlin DSL version of a gradle build script. It is type-checked properly by IntelliJ and provides code completion way more consistently than Groovy. Consistency can also be seen in only using double quotes, only using one way to declare dependencies, type checked task configuration, etc.

The generateLabracoreClient task is new but inactive because this new task was created with Labracore in mind. It will be activated in the first Labracore Merge.

Finally, some license headers added to statically served content should never have been added as they overwrite licenses placed there by the original writers. These headers were removed and the files were excluded from the build process.

Merge request reports