Skip to content

Instantly share code, notes, and snippets.

@pietrom
Created April 8, 2015 07:25
Show Gist options
  • Save pietrom/84f1562b1dbea8008d14 to your computer and use it in GitHub Desktop.
Save pietrom/84f1562b1dbea8008d14 to your computer and use it in GitHub Desktop.
Gradle build file which gets dependencies into a local 'runtime' directory (in order to calculate dependencies footprint - for hibernate-core in the example)
apply plugin: 'java'
dependencies {
runtime group: 'org.hibernate', name: 'hibernate-core', version: '4.3.8.Final'
}
configurations {
runtime.exclude group: 'xml-apis', module: 'xml-apis'
runtime.exclude group: 'org.hibernate.javax.persistence', module: 'hibernate-jpa-2.1-api'
}
repositories { mavenCentral() }
task getDeps(type: Copy) {
from sourceSets.main.runtimeClasspath
into 'runtime/'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment