I've a Gradle project structure and I'm using eclipse. I've installed Gradle plugin for Eclipse.
However tasks aren't shown in Gradle Tasks panel, so I'm not able to launch these ones.
project/
build.gradle
settings.gradle
.project
.classpath
I'm able to perform any task using command line.
Any ideas?
In gradle tasks tab -> navigate to the project -> expand build folder -> right click on build -> Select Run Gradle tasks.
Open the Gradle tool window. Right-click the task for which you want to create the Run configuration. From the context menu select Modify Run Configuration. In Create Run Configuration: 'task name', you can use the default settings or configure the additional options and click OK.
To see which tasks are available for our build we can run Gradle with the command-line option -t or --tasks. Gradle outputs the available tasks from our build script. By default only the tasks which are dependencies on other tasks are shown. To see all tasks we must add the command-line option --all.
I assume you are using Buildship.
The Gragle Tasks view only shows tasks having properties group
and description
task myTask {
group = 'my group'
description = 'my description'
}
After changing your build.gradle
you must 1.) gradle-refresh the project and 2.) refresh the TasksView
For Eclipse 2020-03 and Eclipse Buildship 3.1.3 you can adjust the filter of your Gradle Tasks view to "Show All Tasks". Then you see your tasks which do not have a group set in the "other" section.
The task "compileJava" has no group set and is showed in the other section only if the filter "Show All Tasks" is set:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With