Intellij Gradle plugin: task spamming in the master project :(

Hi,

I am using Gradle for a multi-project project. It's basically one master project (with absolutely no gradle plugin applied) and a couple of child projects. Mostly using the Gradle 'java' plugin. One is using the 'android' plugin from Google.

Running the Gradle build on the command line shows that the master project has basically no tasks - which is expected since it doesn't apply and plugins and servers just as a container for the child project.

Here is the problem now: in the Intellij Gradle Tool Window the master-project somehow (incorrectly) shows to have ALL the tasks from its child projects. This is very annoying since there are sooo many tasks. I have to scroll very long to get to the actual child projects in this Gradle Tool Window.

I would understand if the Master Project would show the tasks that are common to ALL child projects. This way you could execute all tasks with a certain name in all child projects with a single double click. But no. The master project node lists ALL tasks. Even tasks that are specific to a single child project.

This clearly is a bug since the Gradle Tool Window is hardly useable this way. Can I somehow trick the master node not to list ALL tasks of its child projects?

Cheers,
sb

4 comments
Comment actions Permalink

Hi,

sirbender wrote:

Here is the problem now: in the Intellij Gradle Tool Window the master-project somehow (incorrectly) shows to have ALL the tasks from its child projects.


The list (tasks in the root project node) contains all tasks runnable from root project. You can check it using gradle command line:


$ cd master_project_folder
$ gradle tasks


I agree that current tasks tree layout is not convenient to use in case of multi-project with many tasks.
This usability problem will be addressed in IDEA 14. You can watch/vote for related issue at http://youtrack.jetbrains.com/issue/IDEA-122765

Thanks

0
Comment actions Permalink

I see a lot more tasks in the UI of IDEA then what I get from "gradle tasks" in the master project. Especially for Android I see a ton of tasks but also many Java tasks (tested on IDEA13.1 and EAP14). The console only shows me a few tasks: androidDependencies, signingReport and 6 install tasks.

I attached a screenshot.



Attachment(s):
Screenshot from 2014-09-10 10:45:11.png
0
Comment actions Permalink

But all these tasks are runnable from root project, aren't they?

0
Comment actions Permalink

Yes. They are all runnable.

Another thing I was wondering is that the command line allows executing tasks like 'gradle build' in the master project. It then executes all the build tasks from its children. It doesn't have a build task of its own since I never applied any plugin. I guess this is expected behaviour since it makes everything more efficient.

0

Please sign in to leave a comment.