Sergej Koščejev
06/26/2024, 6:45 AMconfig.files(config.dependencies.single()) but Configuration#files(Dependency...) is deprecated now and the message suggests to use incoming.artifactView with componentFilter. So I guess it would be something like this:
val dependency = config.dependencies.single()
val file = config.incoming.artifactView { componentFilter { (it is ModuleComponentIdentifier) && it.group == dependency.group && it.module == dependency.name } }
Is that correct? Is it also correct that the code I have won't work with e.g. a ProjectDependency? Is there a different approach that would support any kind of dependency?Vampire
06/26/2024, 6:51 AMSergej Koščejev
06/26/2024, 9:00 AM> Expected configuration ':detachedConfiguration1' files to contain exactly one file, however, it contains no files.
This is the code:
val pluginConfig = project.configurations.detachedConfiguration()
.extendsFrom(backendConfig.get())
.setTransitive(false)
result.add("--plugin=de.itemis.mps.buildbackends.remigrate::" + pluginConfig.incoming.files.singleFile)Sergej Koščejev
06/26/2024, 9:18 AMVampire
06/26/2024, 9:21 AMSergej Koščejev
06/26/2024, 9:21 AMVampire
06/26/2024, 9:21 AMVampire
06/26/2024, 9:22 AMSergej Koščejev
06/26/2024, 9:25 AMVampire
06/26/2024, 9:27 AMVampire
06/26/2024, 9:28 AMVampire
06/26/2024, 9:29 AMSergej Koščejev
06/26/2024, 9:31 AMproject.configurations.detachedConfiguration(*backendConfig.get().allDependencies.toTypedArray())
(I'd like to avoid an attached configuration because it then unnecessarily participates in dependency locking when lockAllConfigurations() is used.)Vampire
06/26/2024, 9:36 AMVampire
06/26/2024, 9:36 AMVampire
06/26/2024, 9:37 AMproject at execution timeVampire
06/26/2024, 9:37 AMVampire
06/26/2024, 9:38 AMSergej Koščejev
06/26/2024, 9:39 AMVampire
06/26/2024, 9:43 AMSergej Koščejev
06/26/2024, 9:46 AMVampire
06/26/2024, 9:48 AMThomas Broyer
06/26/2024, 9:54 AMresolvedConfiguration.firstLevelModuleDependencies or similar APIs.Thomas Broyer
06/26/2024, 9:55 AMSergej Koščejev
06/26/2024, 9:56 AMSergej Koščejev
06/26/2024, 6:50 PMThomas Broyer
06/26/2024, 6:56 PM