Jakub Chrzanowski
08/05/2024, 7:59 PMexclusiveContent filters defined twice – none of the repositories is eventually picked for the dependency resolution. Is that an expected/known issue?
plugins {
id("java")
}
repositories {
mavenCentral {
exclusiveContent {
forRepositories(this@mavenCentral)
filter {
includeGroup("junit")
includeGroup("org.hamcrest")
}
}
}
mavenCentral {
exclusiveContent {
forRepositories(this@mavenCentral)
filter {
includeGroup("junit")
includeGroup("org.hamcrest")
}
}
}
}
dependencies {
testImplementation("junit:junit:4.13.2")
}
This fails with:
foo:test: Could not find junit:junit:4.13.2.
Required by:
project :Vampire
08/05/2024, 8:19 PMJakub Chrzanowski
08/05/2024, 8:22 PMVampire
08/05/2024, 8:22 PMVampire
08/05/2024, 8:23 PMVampire
08/05/2024, 8:23 PMVampire
08/05/2024, 8:23 PMJakub Chrzanowski
08/05/2024, 8:23 PMVampire
08/05/2024, 8:24 PMJakub Chrzanowski
08/05/2024, 8:25 PMVampire
08/05/2024, 8:25 PMVampire
08/05/2024, 8:26 PMVampire
08/05/2024, 8:26 PMVampire
08/05/2024, 8:26 PMJakub Chrzanowski
08/05/2024, 8:27 PMnotThatExclusiveContent then? 😉Vampire
08/05/2024, 8:27 PMJakub Chrzanowski
08/05/2024, 8:28 PMJakub Chrzanowski
08/05/2024, 8:29 PMVampire
08/05/2024, 8:29 PMrepositories.configureEach {
if (this is not_my_special_repo) {
content {
exclude...
}
}
}Vampire
08/05/2024, 8:30 PMI want to make sure that one repository won’t be used for searching any other dependencies than requested – as it is supposed to serve just a specific content with fixed group.then exclusive content is wrong anyway
Vampire
08/05/2024, 8:30 PMVampire
08/05/2024, 8:31 PMcontent { include... }Vampire
08/05/2024, 8:31 PMVampire
08/05/2024, 8:31 PMVampire
08/05/2024, 8:32 PMVampire
08/05/2024, 8:32 PMJakub Chrzanowski
08/05/2024, 8:36 PMJakub Chrzanowski
08/05/2024, 8:36 PM