Slackbot
03/17/2022, 2:49 PMJendrik Johannes
03/17/2022, 3:50 PMstatus
attribute from the version at resolution time. E.g. a rule like that:
@CacheableRule
abstract class ComponentStatusRule : ComponentMetadataRule {
override fun execute(context: ComponentMetadataContext) {
val version = context.details.id.version
val lcVersion = version.toLowerCase()
if (lcVersion.contains("alpha")
|| lcVersion.contains("-b")
|| lcVersion.contains("beta")
|| lcVersion.contains("cr")
|| lcVersion.contains("m")
|| lcVersion.contains("rc")) {
context.details.status = "integration"
}
}
}
dependencies.components {
all<ComponentStatusRule>()
}
Of course all the projects in your organisation then needs to use this rule…..
On the upside you also get the “right” status for the external libraries that are published on Maven Central.Peter vR
03/17/2022, 3:55 PMJendrik Johannes
03/17/2022, 4:03 PM