I am using kotlin 1.7.20 as below
classpath ("org.jetbrains.kotlin:kotlin-gradle-plugin:1.7.20")
When I acess below firebase code from a normal build.gradle, it gets compiled. But when used from inside of buildSrc, I get error as kotlin 1.5.1 module was expected, but found 1.7.1
plugins {
`kotlin-dsl`
}
repositories {
google()
mavenCentral()
}
dependencies {
// firebase
implementation (platform("com.google.firebase:firebase-bom:31.0.2"))
implementation ("com.google.firebase:firebase-firestore-ktx")
}
Error is like below
/Users/xx/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-common/1.7.10/0d0a9e3f3673ba/kotlin-stdlib-common-1.7.10.jar!/META-INF/kotlin-stdlib-common.kotlin_module: Module was compiled with an incompatible version of Kotlin. The binary version of its metadata is 1.7.1, expected version is 1.5.1.
My main requirement is to trigger firebase in case of gradle sync through custom task.
I tried changing the values, but didn't work