ktlint-gradle icon indicating copy to clipboard operation
ktlint-gradle copied to clipboard

Document how to execute it on Java 16

Open lukas-krecan opened this issue 4 years ago • 5 comments

Can you please document how to execute the plugin on Java 16 with stricter module check. It's necessary to pass a JVM argument to open java.base module, but I could not find how to do it. See this SO question.

lukas-krecan avatar Mar 27 '21 18:03 lukas-krecan

I think you have to use Gradle 7 as it only in this release have added JDK 16 support.

If it will not help, please let me know.

Tapchicoma avatar Apr 06 '21 10:04 Tapchicoma

That's a pity. It seems that the rest of the ecosystem works with Gradle 6 and Java 16 (Kotlin compiler, Koltin DSL, ...). I would expect that somehow passing org.gradle.jvmargs to the Gradle plugin execution should help, but my knowledge of Gradle plugins is limited.

lukas-krecan avatar Apr 06 '21 11:04 lukas-krecan

Interesting, I will see if it can be fixed from the plugin side :thinking:

/cc @JLLeitschuh

Tapchicoma avatar Apr 06 '21 11:04 Tapchicoma

Supposedly, support for Java 16 is only in Gradle 7. I'd advise that we add it to the matrix for CI and see what fails.

JLLeitschuh avatar Apr 07 '21 17:04 JLLeitschuh

Kotlin itself doesn't really support JDK 16 until Kotlin 1.5

ZacSweers avatar Apr 13 '21 18:04 ZacSweers