Paul, you're a genius !!
I'm not sure if this won't break on future Gradle versions, but it works on
0.9.1.
The pattern is, on the main build script :
buildscript {
apply from: 'common.gradle'
}
task sth << {
// use dependency declared by common.gradle here
}
And the common.gradle :
project.buildscript {
repositories { ... }
dependencies { ... }
}
BOTH the following conditions must be satisfied:
1. common.gradle must be included WITHIN buildscript closure
2. Inside common.gradle, it must use "project.buildscript" or
"rootProject.buildscript"
-----
http://www.HendyIrawan.com
--
View this message in context:
http://gradle.1045684.n5.nabble.com/buildscript-cannot-be-put-inside-external-gradle-script-tp3334836p3335177.html
Sent from the gradle-user mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email