Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there something like the effective pom (Maven) in Gradle?

Tags:

gradle

I've started using Gradle several months ago and I sometimes bump into a problem with my build.gradle files. For example if I add something like this to my file:

apply plugin: 'kotlin'

I can't tell what that will expand to. In my case I figured out that it pulls in the java plugin as well and the java plugin itself sets up some configuration. How do I know what these statements will expand to? Do Gradle has something like an effective build.gradle ?

Clarification: what I really wish to know is what each apply plugin X statement does behind the scenes without looking up documentations etc.

like image 425
Adam Arold Avatar asked Dec 12 '16 17:12

Adam Arold


People also ask

Does Gradle have a pom?

Gradle is an extensible and very flexible build tool capable of building projects that target many platforms, not just Java.

Is Gradle really better than Maven?

Summary of performance resultsGradle is between 7 and 85 times faster than Maven when building incremental changes; benefits increase with number of subprojects. Gradle builds are 3 to 30 times faster than Maven builds when task outputs can be resolved Gradle's build cache.

Can Gradle use Maven dependency?

Gradle can consume dependencies available in the local Maven repository.

What is effective POM in Maven?

The effective-pom goal is used to make visible the POM that results from the application of interpolation, inheritance and active profiles. It provides a useful way of removing the guesswork about just what ends up in the POM that Maven uses to build your project.


1 Answers

Try gradle dependencies. The output is similar to Maven's mvn dependency:tree.

See docs here: https://docs.gradle.org/current/userguide/inspecting_dependencies.html#example_rendering_the_dependency_report_for_a_custom_configuration

like image 99
David Good Avatar answered Oct 15 '22 08:10

David Good