Gradle plugin for JVM projects written in Java, Kotlin, Groovy, or Scala; and Android projects written in Java or Kotlin. Provides advice for managing dependencies and other applied plugins
Apache License 2.0
1.66k
stars
116
forks
source link
Feature Request: Advice on modules that could/should be combined #1193
Is your feature request related to a problem? Please describe.
Sometimes when you modularize a codebase the final structure is not clear and you might "over-modularize", meaning things that should be in a single module are separated into multiple modules
Describe the solution you'd like
Would like the plugin to give advice on which module are good candidates for combining into a single module.
a couple of heuristics on when you might want to combine modules:
when any given module depends onA it also depends on module B XX% (configurable) of the time, and vice versa.
module A and module B apply the same (or mostly the same) plugins ("mostly same" should be configurable)
module A and module B have the same (or mostly the same) dependencies ("mostly same" should be configurable)
module A and module B are less than NNN (configurable) lines of code when combined (don't want to create huge modules)
if some combination of those things are true, then "combineModuleAdvice" should propose combining module A and B
Additional context
I generally like to start with smallest modules possible, see what structure emerges, and then combine modules that are similar.
Is your feature request related to a problem? Please describe.
Sometimes when you modularize a codebase the final structure is not clear and you might "over-modularize", meaning things that should be in a single module are separated into multiple modules
Describe the solution you'd like Would like the plugin to give advice on which module are good candidates for combining into a single module.
a couple of heuristics on when you might want to combine modules:
A
it also depends on moduleB
XX% (configurable) of the time, and vice versa.A
and moduleB
apply the same (or mostly the same) plugins ("mostly same" should be configurable)A
and moduleB
have the same (or mostly the same) dependencies ("mostly same" should be configurable)A
and moduleB
are less than NNN (configurable) lines of code when combined (don't want to create huge modules)if some combination of those things are true, then "combineModuleAdvice" should propose combining module
A
andB
Additional context
I generally like to start with smallest modules possible, see what structure emerges, and then combine modules that are similar.