Skip to content

Commit 9bba733

Browse files
committed
Clarify module naming patterns in README
Addition to 0477046 Fixes #10
1 parent a5e5b61 commit 9bba733

File tree

1 file changed

+10
-8
lines changed

1 file changed

+10
-8
lines changed

README.MD

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -54,18 +54,20 @@ javaModuleDependencies {
5454
}
5555
```
5656

57-
## Modules in the build (module name = name + . + group)
57+
## Naming patterns for Modules in the build
5858

59-
This plugin makes the following assumption about _Module Names_ of your own modules in the build to establish dependencies between them:
59+
This plugin makes the following assumption about _Module Names_ of your own Modules in the build to establish dependencies between them:
6060

61-
- **Module Name** == `"${project.name}.${project.group}"`
61+
- **Module Name** == `"${prefixOfYourChoice}.${project.name}`
6262

63-
A project name is determined by the `include(projectName)` statement in the settings file.
64-
The group is defined via the `group = ...` statement in the build files / convention plugin.
65-
This corresponds to how GA coordinates are typically mapped to module names.
63+
Or:
6664

67-
If you do not follow this pattern, you can also use a prefix that differs from the group:
68-
`javaModuleDependencies.ownModuleNamesPrefix.set("org.my.module.name.prefix")`.
65+
- **Module Name** == `"${prefixOfYourChoice}.${project.name}.${sourceSet.name}"`
66+
67+
A `project.name` is determined by the `include(projectName)` statement in the settings file.
68+
A `sourceSet.name` is typically the name of the folder where the sources are located - e.g _main_ or _test_.
69+
70+
If you have a `prefixOfYourChoice`, all your modules **need to have the same prefix** in order for the plugin to establish dependencies between the projects.
6971

7072
## Defining module versions
7173

0 commit comments

Comments
 (0)