1jcnfa
Last Updated: February 25, 2016
·
3.024K
· gamussa
0680be1c881abcf19219f09f1e8cf140

Gradle: collect application dependencies

I'm using gradle as build tool on current project. Gradle has great dependency management features. Gradle can easily fetch application dependencies from maven central repositories. But some time you need to collect all dependencies jars locally (e.g. to figure out dependencies of dependencies or what actual jars you depend on).
This task could be done by followed gradle task:

task collectJars(type: Copy){
    into "$buildDir/output/lib"
    from configurations.testRuntime
}

After running

gradle collectJars

you can find all you dependencies in you build/output/lib directory

Say Thanks
Respond