SDKMan, adding unlisted versions

SDKMan is a fantastic tool, I believe no one has doubts! Since I installed it, my concerns with Gradle, Java, Kotlin versions, among other SDKs ended… As a JVM developer, just not needing to adjust the infamous JAVA_HOME, M2_HOME and others, have already turned my days into happier days.

Something, however, gave me a certain headache that I would like to share with you:

I recently started implementing a project with Java 12. At first, I thought, just install this version with SDKMan, however, I was mistaken… the version didn’t appear on any of the vendors when I ran sdk list java.

I still don’t understand the reason for this gap, but I started to think about alternatives… I could install the version 16 and make use of the Java retrocompatibility, however, this started to look as a work around.

I even thought about installing the pre-SDKMan, however, I was wondering how the Java version management at two distinct points on my operating system, in addition to possible changes to my POM to avoid compilation version errors. After some research I found post on StackOverflow, a solution that I thought was more elegant.:

It seems that downloading the missing version, then unpacking to: ~/.sdkman/candidates/java/ then renaming the extracted directory solves the problem.

With that, I continued using only 1 manager of Java in my operational system, taking advantage of the facilities of SDKMan! SDKMan is life!!!

原文链接:SDKMan, adding unlisted versions

© 版权声明
THE END
喜欢就支持一下吧
点赞13 分享
评论 抢沙发

请登录后发表评论

    暂无评论内容