Skip to content

Commit 63b4225

Browse files
committed
fix(bulk-model-sync-gradle): clearly exit with error if no module matched the inclusion criteria
1 parent 718a8bc commit 63b4225

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

bulk-model-sync-mps/src/main/kotlin/org/modelix/mps/model/sync/bulk/MPSBulkSynchronizer.kt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,15 @@ object MPSBulkSynchronizer {
9797
val includedModules = allModules.filter {
9898
isModuleIncluded(it.moduleName!!, includedModuleNames, includedModulePrefixes)
9999
}
100+
101+
require(includedModules.isNotEmpty()) {
102+
"""
103+
No module matched the inclusion criteria.
104+
[includedModules] = $includedModuleNames
105+
[includedModulePrefixes] = $includedModulePrefixes
106+
""".trimIndent()
107+
}
108+
100109
val numIncludedModules = includedModules.count()
101110
val outputPath = System.getProperty("modelix.mps.model.sync.bulk.output.path")
102111
val counter = AtomicInteger()

0 commit comments

Comments
 (0)