* direct |
- * Flatten only the direct dependency versions.
- * This is the default mode and compatible with Flatten Plugin prior to 1.2.0. |
+ * Flatten only the direct dependency versions, excluding inherited dependencies from a parent module.
+ * This was the default mode with Flatten Plugin in versions 1.4.0 up to 1.6.0.
+ * |
+ *
+ *
+ * inherited |
+ * Flatten the dependency versions, including inherited dependencies from a parent module
+ * This is the default mode and compatible with Flatten Plugin prior to 1.2.0, this mode was called direct between versions 1.2.0 and 1.3.0.
+ * |
+ *
*
* all |
* Flatten both direct and transitive dependencies. This will examine the full dependency tree, and pull up
@@ -1217,7 +1225,9 @@ protected void createFlattenedDependencies(Model effectiveModel, List projectDependencies = currentProject.getOriginalModel().getDependencies();
List projectDependencies = effectiveModel.getDependencies();
- if (flattenDependencyMode == null | flattenDependencyMode == FlattenDependencyMode.direct) {
+ if (flattenDependencyMode == null
+ || flattenDependencyMode == FlattenDependencyMode.direct
+ || flattenDependencyMode == FlattenDependencyMode.inherited) {
createFlattenedDependenciesDirect(projectDependencies, flattenedDependencies);
} else if (flattenDependencyMode == FlattenDependencyMode.all) {
try {
|