How I add plugin in build.gradle. Source: https://plugins.gradle.org/plugin/com.asyncapi.asyncapi-gradle-plugin
buildscript {
repositories {
maven {
url = uri("https://plugins.gradle.org/m2/")
}
}
dependencies {
classpath("com.asyncapi:asyncapi-gradle-plugin:1.0.0-EAP.1")
}
}
apply(plugin = "com.asyncapi.asyncapi-gradle-plugin")
I get error:
A problem occurred configuring root project 'java-backend'.
> Could not resolve all files for configuration ':classpath'.
> Could not find com.asyncapi:asyncapi-core:1.0.0-SNAPSHOT.
Searched in the following locations:
- https://plugins.gradle.org/m2/com/asyncapi/asyncapi-core/1.0.0-SNAPSHOT/maven-metadata.xml
- https://plugins.gradle.org/m2/com/asyncapi/asyncapi-core/1.0.0-SNAPSHOT/asyncapi-core-1.0.0-SNAPSHOT.pom
Required by:
project : > com.asyncapi:asyncapi-gradle-plugin:1.0.0-EAP.1 > com.asyncapi:asyncapi-plugin-core:1.0.0-EAP
Possible solution:
- Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html
the repository must be searched by path https://plugins.gradle.org/m2/com/asyncapi/asyncapi-gradle-plugin/1.0.0-EAP.1/ ...Why is he looking for another way?
Try changing it from
1.0.0-EAP.1
to1.0.0-EAP-1
. If it doesn't works, it's also available on mvncentral.