Gradle Dep Tree banner
jfrog jfrog

Gradle Dep Tree

Development community

Description

Gradle plugin that reads the Gradle dependencies of a given Gradle project, and generates a dependency tree.

Installation

This entry records only its repository, not the path inside it, so there is no exact command to give. Open the source below and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

README

[![Scanned by Frogbot](https://raw.github.com/jfrog/frogbot/master/images/frogbot-badge.svg)](https://github.com/jfrog/frogbot#readme) [![Test](https://github.com/jfrog/gradle-dep-tree/actions/workflows/test.yml/badge.svg?branch=main)](https://github.com/jfrog/gradle-dep-tree/actions/workflows/test.yml)

🐘 Gradle Dependency Tree

This Gradle plugin reads the Gradle dependencies of a given Gradle project, and generates a dependency tree. This package was developed by JFrog, and is used by the [JFrog IntelliJ IDEA Plugin](https://plugins.jetbrains.com/plugin/9834-jfrog) to generate the dependency tree for projects using Gradle dependencies. You may find this plugin useful for other purposes and applications as well, by applying it in your build.gradle file.

🖥️ Usage

Inject the plugin using the [init.gradle](./init.gradle) initialization script, and run *generateDepTrees* in a directory containing a build.gradle file. The plugin will generate a dependency tree for each subproject that does not contain a build.gradle file. To generate a dependency tree for each subproject that contains a Gradle build file, set the `-Dcom.jfrog.includeAllBuildFiles` flag to `true`.

To skip Gradle configurations whose names match a regex, set `-Dcom.jfrog.excludeConfigurationsPattern=`. For example, to skip names containing `test` case-insensitively (including `testImplementation`, `androidTest*`, and also `testFixtures*` / accidental substring hits like `latestReleaseApi`):

gradle clean generateDepTrees -I  -q \
  -Dcom.jfrog.depsTreeOutputFile= \
  -Dcom.jfrog.excludeConfigurationsPattern=(?i)test

If the property is omitted or blank, all configurations are included. Invalid regex fails the task.

The command:

gradle clean generateDepTrees -I  -q -Dcom.jfrog.depsTreeOutputFile=

Output:

""
""
...