Skip to content

Instantly share code, notes, and snippets.

Avatar

Keegan Witt keeganwitt

View GitHub Profile
@keeganwitt
keeganwitt / gradle-dependency-analyze.gradle
Created Jan 31, 2018 — forked from kellyrob99/gradle-dependency-analyze.gradle
A simple Gradle wrapper for the maven dependency:analyze goal
View gradle-dependency-analyze.gradle
import org.apache.maven.shared.dependency.analyzer.ClassAnalyzer
import org.apache.maven.shared.dependency.analyzer.DefaultClassAnalyzer
import org.apache.maven.shared.dependency.analyzer.DependencyAnalyzer
import org.apache.maven.shared.dependency.analyzer.ProjectDependencyAnalysis
import org.apache.maven.shared.dependency.analyzer.asm.ASMDependencyAnalyzer
import org.gradle.api.Project
import org.gradle.api.artifacts.ConfigurationContainer
import org.gradle.api.artifacts.ResolvedArtifact
import org.gradle.api.artifacts.ResolvedDependency
@keeganwitt
keeganwitt / dependency-report.gradle
Created Jan 31, 2018 — forked from tzachz/dependency-report.gradle
Gradle: multi-project dependency graph (supports depth > 2)
View dependency-report.gradle
// Inspired by https://gist.github.com/abesto/cdcdd38263eacf1cbb51
// Task creates a .dot file with all inter-module dependencies
// Supports any depth of nested modules
task moduleDependencyReport {
doLast {
def file = new File("project-dependencies.dot")
file.delete()
file << "digraph {\n"
file << "splines=ortho\n"