I am using a multi-modular architecture for my android app with module grouping i.e. I group my modules under a directory to make it more organised. The structure is similar to this-
MyApplication
├───app
├───common
│ ├───network
│ └───presentation
...
Note that common is just a directory and not a module. Whereas, network and presentation both are android modules.
Now when I try to print the name of all the modules in build.gradle in either of afterEvaluate or subProjects-
afterEvaluate { project ->
println("Project name is: "+ project.name)
}
Only two module names are printed i.e. app and common.
But common is not really a module and the modules inside common are not printed as somehow gradle (or studio) doesn't understand that it's just a module group.
The main intent is to identify if the given module is an android module or just a kotlin/java module. But since gradle doesn't even list down network and presentation I am not able to identify the type of module.
How can I get all the modules listed while using grouping?