https://kotlinlang.org logo
g

Gurupad Mamadapur [FH]

01/21/2020, 11:40 AM
Is there a way to easily switch between different versions of the Kotlin plugin. Say I want to test out a plugin in EAP channel and then revert to a stable channel plugin. Right now will have load plugin from disk to downgrade.
What do the Jetbrains folks do?
i

Ivan Kubyshkin [JetBrains]

01/21/2020, 11:51 AM
You should add this code to your settings.gradle
Copy code
pluginManagement {
    repositories {
        maven { url '<http://dl.bintray.com/kotlin/kotlin-eap>' }
        maven { url '<http://dl.bintray.com/kotlin/kotlin-dev>' }
        mavenCentral()
    }
}
And this code to build.gradle:
Copy code
repositories {
    mavenCentral()
    maven { url '<http://dl.bintray.com/kotlin/kotlin-eap>' }
    maven { url '<http://dl.bintray.com/kotlin/kotlin-dev>' }

}
after these actions you can change the code in
plugins {}
block
Copy code
id 'org.jetbrains.kotlin.jvm' version '1.3.61'
or
Copy code
id 'org.jetbrains.kotlin.jvm' version '1.3.70-eap-96'
a

Alexey Belkov [JB]

01/21/2020, 12:02 PM
^ This is only relevant for the gradle plugin. For the IDE plugin, "install from disk" is your best bet. Alternatively, you could just keep two different versions of the IDE installed with different plugins.
👍 1
g

Gurupad Mamadapur [FH]

01/21/2020, 12:29 PM
@Alexey Belkov [JB] Okay, would be nice if Kotlin plugin has an option to manually pick the previous version for downgrading. Edit: Ah, but I guess there is no need to downgrade if the newer is backwards compatible.
4 Views