The JDepend plugin performs quality checks on your project’s source files using JDepend and generates reports from these checks.
⚠
|
Since JDepend is unmaintained and does not support bytecode compiled for Java 8 and above, the JDepend plugin has been deprecated and is scheduled to be removed in Gradle 6.0. |
Usage
To use the JDepend plugin, include the following in your build script:
Groovy
Kotlin
plugins {
id 'jdepend'
}
The plugin adds a number of tasks to the project that perform the quality checks. You can execute the checks by running gradle check
.
Note that JDepend will run with the same Java version used to run Gradle.
Tasks
The JDepend plugin adds the following tasks to the project:
jdependMain
— JDepend-
Depends on:
classes
Runs JDepend against the production Java source files.
jdependTest
— JDepend-
Depends on:
testClasses
Runs JDepend against the test Java source files.
jdependSourceSet
— JDepend-
Depends on:
sourceSetClasses
Runs JDepend against the given source set’s Java source files.
The JDepend plugin adds the following dependencies to tasks defined by the Java plugin.
Additional task dependencies
check
-
All JDepend tasks, including
jdependMain
andjdependTest
.
Dependency management
The JDepend plugin adds the following dependency configurations:
Dependency configurations
jdepend
-
The JDepend libraries to use