Menu

How to switch Java versions on Windows with one command (no more editing JAVA_HOME)
📰

How to switch Java versions on Windows with one command (no more editing JAVA_HOME)

DEV Community: rust·captivator·10 days ago
#oGYmT7kC
#devtorust#devto#dev#java#path
Reading 0:00
15s threshold

I kept juggling JDK 8, 21 and 25 on Windows. Every time a project needed a different one, I was back in the environment variables dialog, editing JAVA_HOME and then checking PATH to make sure the right java.exe won.

So I made jfs (see what it stands for at the end), a Windows Java version manager for Java fans.

qaptivator / jfs

Windows Java version manager for Java fans. Switch JDKs with one command. No shims, no shell hooks, no background service.

jfs

Stop editing JAVA_HOME .

jfs (Java Fucking Sucks) is a Windows Java version manager. Point it at JDKs you already have, then switch with one command. Your actual JAVA_HOME environment variable stays unchanged. Behind the scenes, a directory junction moves.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.