This message was deleted.
# community-support
s
This message was deleted.
c
It is still the case.
The command
gradle test
will execute the
test
task in any subprojects, relative to the current working directory, that have that task. If you run the command from the root project directory, you’ll run
test
in api, shared, services:shared and services:webservice. If you run the command from the services project directory, you’ll only execute the task in services:shared and services:webservice.
https://docs.gradle.org/current/userguide/intro_multi_project_builds.html
👍 1
g
thanks
👍 1
I was checking against a task publishing to
build/repo
, it turns out I was looking only in the root, while every module has obviously its own
build
v
It's not the full truth though. If you run explicitly the root projects task using its full path
:build
, then only the root projects
build
task is executed unless you configured task dependencies manually. If you run a task without any path (i.e. without it containing a
:
separator), then the magic kicks in that runs the task in all projects that have a task with that name.
👍 1
If you for example trigger the root projects
build
task through the IDE tool window, it is equivalent to executing
:build
, not
build
.
g
no wait, I'm actually triggering a task through the IDE tool window, and it's calling in turn the tasks on the modules..
c
If you for example trigger the root projects
build
task through the IDE tool window, it is equivalent to executing
:build
, not
build
.
This isn’t what is observed. A run configuration is created with
build
as the target, and all build targets in root and subprojects are executed. At least that is the case in IntelliJ.
v
Oh, ok, then I had that detail wrong in mind, sorry. I usually use Ctrl-Ctrl to run Gradle tasks, not the tool window.
c
all good, so many options…
g
it's ok, Vampire, only we peasant use the GUI 😬
v
Ctrl-Ctrl is also GUI 😄
🙈 1