Created
March 5, 2012 02:46
-
-
Save clmarquart/1976155 to your computer and use it in GitHub Desktop.
Gradle buildscript project dependency
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Gradle doesn't allow project dependencies within the buildscript | |
* classpath closure. This is a workaround I came up with to use | |
* the built Jar of a project in the classpath of another project's | |
* buildscript. | |
* | |
* View it in action: https://github.com/gripes/gripes-test/blob/master/build.gradle | |
*/ | |
buildscript { | |
project.getTasks().add([name: "gripes", type: GradleBuild]) { | |
buildFile = '../gripes-plugin/build.gradle' | |
tasks = ['pluginJar'] | |
}.execute() | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
I have the same requirement of using the plugin module inside another module in the same multi-module structure. I've got the example code here . But if I add the code you have suggested, then the build goes in an indefinite loop.
Please have a look at the example code and let me know if I've done something incorrectly.
Thanks
Adee