In addition to optimize build it maybe make sense add this:
`compileJava.enabled = compileTestJava.enabled = false`