I'm trying to import the atomicfu plugin using Gra...
# announcements
e
I'm trying to import the atomicfu plugin using Gradle, but the dependency is unresolved. Do I need a particular repository?
You can find repo in top right side (with copy button)
e
@turansky thanks, I'll try!
@turansky nope, still not found. Here is the error
Copy code
Plugin Repositories (could not resolve plugin artifact 'kotlinx-atomicfu:kotlinx-atomicfu.gradle.plugin:0.15.0')
Searched in the following repositories:
  Gradle Central Plugin Repository
  MavenRepo
  maven(<https://kotlin.bintray.com/kotlinx>)
  BintrayJCenter
t
You need Gradle resolution strategy (in
setings.gradle.kts
) as I see to download this artifact instead:
Copy code
org.jetbrains.kotlinx:atomicfu-gradle-plugin:0.15.0
Copy code
pluginManagement {
    repositories {
        gradlePluginPortal()
        maven("<https://kotlin.bintray.com/kotlinx>)")
    }

    resolutionStrategy {
        eachPlugin {
            when (requested.id.id) {
                "kotlinx-atomicfu"
                -> useModule("org.jetbrains.kotlinx:atomicfu-gradle-plugin:${requested.version}")
            }
        }
    }
}
e
@turansky worked! Thanks! But I didn't see it mentioned in the readme
t
Looks like possible PR from @Edoardo Luppi ­čÖé
­čśä 1
e
@turansky seems reasonable