[GRADLE-2434] Tooling API should provide information about 'aggregated' tasks Created: 13/Aug/12 Updated: 20/Mar/14 Resolved: 20/Mar/14 |
|
Status: | Resolved |
Project: | Gradle |
Affects Version/s: | 1.1 |
Fix Version/s: | 1.12-rc-1 |
Type: | New Feature | ||
Reporter: | Kris De Volder | Assignee: | Radim Kubacki |
Resolution: | Fixed | Votes: | 1 |
Description |
This issue is motivated by an issue that a user raised a while back with STS tooling here: Note: the wording 'aggregated task' is terminology that I am not sure is actually correct 'Gradle Speak'. But I hope the description is clear enough. Essentially, I think what the user is poiting out is that we don't have a mechanism to do something like "run all tasks called 'test' on all this project's subprojects". I could imagine an option checkbox in the STS UI that says 'show aggregated tasks'. When selected, we would show the union of the names of all tasks on a given project and all of its subprojects, and when such an 'aggregated task' is executed it would actually execute the task with that name on all projects. I could probably implement this kind of task agregation on the STS side, but I'm reluctant to do so because I recall talking with some of you guys a while back and, I believe, you were saying this is something Gradle already knows how to do (and I would fear if STS is doing it, it may not be equivalent or correct when it comes the analyzing task dependency and deciding task execution order). Thus I think it would be best if the Tooling API would provide some kind of way to retrieve a list of aggregated tasks and execute an aggregated task. Please excuse me if the term 'agregated tasks' is incorrect, feel free to correct me |
Comments |
Comment by Radim Kubacki [ 20/Mar/14 ] |
Now available via http://www.gradle.org/docs/nightly/javadoc/org/gradle/tooling/model/gradle/BuildInvocations.html model as TaskSelector instances. Those can be used to run a build using projectConnection.newBuild().forLaunchables(selector1, selector2, ...) |