Skip to content

Instantly share code, notes, and snippets.

@joninvski
Created July 9, 2014 21:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save joninvski/a34115170e08d9c25fd1 to your computer and use it in GitHub Desktop.
Save joninvski/a34115170e08d9c25fd1 to your computer and use it in GitHub Desktop.
// Top-level build file where you can add configuration options common to all sub-projects/modules.
allprojects {
tasks.withType(Compile) {
options.compilerArgs << "-Xlint:deprecation"
}
task printDependencies << {task -> println "Subproject -> $task.project.name" }
}
subprojects {
printDependencies {
afterEvaluate { Project project ->
if (configurations.find { it.name == 'compile' }) {
doLast {
println "$project.configurations.compile.asPath\n"
}
}
if (configurations.find { it.name == 'androidTestCompile' }) {
doLast {
println "$project.configurations.androidTestCompile.asPath\n"
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment