binary-compatibility-validator icon indicating copy to clipboard operation
binary-compatibility-validator copied to clipboard

java only project check

Open chameleon82 opened this issue 2 years ago • 2 comments

I have multi-module gradle project for java libraries and would like to use plugin for compatibility-check. However, all my modules use plugins { java-library } and checker tasks unavailable until I will add kotlin("jvm") plugin.

Is there any way to configure plugin with no kotlin sources?

chameleon82 avatar Dec 13 '23 03:12 chameleon82

@chameleon82 at the moment, BCV could be only configured for projects where one of Kotlin plugins was applied (jvm, multiplatform, or kotlin-android).

As a quick and dirty workaround, you may check how Kotlin stdlib use BCV: https://github.com/JetBrains/kotlin/blob/master/libraries/tools/binary-compatibility-validator/src/test/kotlin/org.jetbrains.kotlin.tools.tests/RuntimePublicAPITest.kt

fzhinkin avatar Dec 14 '23 13:12 fzhinkin

Related: #94

fzhinkin avatar Apr 09 '24 14:04 fzhinkin

As part of the migration of separate BCV functionality to Kotlin Gradle Plugin, the addition of new features to a separate plugin has been discontinued.

Using the dependency described in task, you can write your own code that will validate binary compatibility in JVM only projects.

shanshin avatar Jun 02 '25 16:06 shanshin