SDKMAN, jEnv, and JetTUI: Three Philosophies for JDK Version Management
SDKMAN vs jEnv vs JetTUI: Which JDK Version Manager Should You Choose?
Three tools, three philosophies. SDKMAN manages broadly, jEnv manages finely, JetTUI manages comprehensively. Which one you choose depends on who you are.
1. Why You Need JDK Version Management
First, confirm whether this sounds like you:
You have JDK 8, JDK 11, JDK 17, and JDK 21 installed on your computer. Old projects use 8, new projects use 17, and experimental ones use 21. The same goes for Maven—versions 3.6 and 3.9 coexist.
Every day you switch between projects, changing JAVA_HOME over and over, messing up your PATH again and again. A compilation error pops up—wrong version. You fix it, restart the terminal, and get another error—still wrong.
You are not alone. Java developers across China spend half their time switching versions.
Today, let's compare the three mainstream JDK version management tools on the market: SDKMAN, jEnv, and JetTUI. By the end, you'll know which one to pick.
2. What Each of the Three Tools Is
SDKMAN: The Veteran All-Rounder
SDKMAN was born around 2013 and is the most well-known SDK version management tool on Unix-like platforms.
It manages more than just JDKs. Go, Maven, Gradle, Kotlin, Scala, Groovy—practically any tool in the JVM ecosystem you can think of, it can install, switch, and uninstall.
The core commands look like this:
sdk list java # List all installable JDKs
sdk install java 17.0.8-tem # Install JDK 17
sdk use java 17.0.8-tem # Switch current shell to 17
sdk default java 17.0.8-tem # Set as default
Key trait: it downloads and installs for you. You don't need to go to Oracle's website to download a JDK yourself; SDKMAN pulls it from the source for you. After installation, it automatically configures JAVA_HOME and PATH.
jEnv: The Lightweight Switching Specialist
jEnv is more focused than SDKMAN. It only manages JDKs, nothing else. And it doesn't download JDKs for you—you install them yourself, and it only handles "switching."
Core commands:
jenv add /usr/lib/jvm/java-17-openjdk # Add an already installed JDK
jenv global 17 # Set global version
jenv local 17 # Use 17 in the current directory
jenv shell 17 # Use 17 in the current shell
Key trait: three levels of granularity. Global, directory-level, and shell-level—switch as finely as you want. Enter a project directory, and it automatically switches to the JDK version that project requires.
The principle is a shim mechanism: jEnv inserts a layer of its own interceptors into PATH. Every time java is called, it first determines which version to use, then forwards the call to the corresponding JDK.
JetTUI: Environment Switching Inside a Terminal Toolbox
JetTUI is not just a version management tool; it's a terminal dashboard for Java developers. Version switching is a feature within its F4 tab.
How to operate:
- Press
F4to enter the environment switching tab - Enter the home directory path of the JDK or Maven
- Click Activate
Key trait: GUI operation + permanent environment variable writing. It doesn't download JDKs for you; you install them yourself and tell it the path. After switching, the change takes effect immediately in the current process and simultaneously writes to the JAVA_HOME, MAVEN_HOME, and PATH user environment variables, so new terminals also retain the setting.
Moreover, JetTUI does more than just switch versions—F1 starts/stops services, F2 compiles, F3 packages. Switching versions is just something you do along the way.
3. Head-to-Head Comparison, Dimension by Dimension
Dimension 1: Platform Support
| Platform | SDKMAN | jEnv | JetTUI |
|---|---|---|---|
| Linux | Native support | Native support | Supported |
| macOS | Native support | Native support | Supported |
| Windows | Requires WSL/Git Bash | Original requires WSL, third-party Windows fork exists | Native support |
This is JetTUI's biggest differentiator. SDKMAN and jEnv are both designed for Unix-like systems. Windows users must either install WSL or use a third-party port, which degrades the experience. JetTUI runs natively on Windows and writes environment variables directly to the system.
If your main machine runs Windows, this single dimension can filter out the other two.
Dimension 2: Operation Method
| Dimension | SDKMAN | jEnv | JetTUI |
|---|---|---|---|
| Interaction | Pure command line | Pure command line | TUI graphical interface + mouse clicks |
| Learning curve | Medium, requires memorizing commands | Medium, requires memorizing commands | Very low, enter a path and click a button |
SDKMAN and jEnv are both command-line tools; you need to remember commands like sdk use and jenv local. They become second nature with practice, but there is a barrier for newcomers.
JetTUI is a TUI with buttons, lists, and input boxes. You can operate it with mouse clicks, no need to memorize shortcuts.
Dimension 3: Version Switching Granularity
| Granularity | SDKMAN | jEnv | JetTUI |
|---|---|---|---|
| Global default | Supported | Supported | Supported |
| Current Shell | Supported | Supported | Supported (current process) |
| Directory-level auto-switch | Not supported | Supported | Not supported |
This is jEnv's killer feature. jenv local 17 creates a .java-version file in the current directory. From then on, entering that directory automatically switches to 17. SDKMAN and JetTUI lack this feature; you must switch manually.
If you have many projects, each requiring a different JDK, jEnv's directory-level switching is a real time-saver.
Dimension 4: SDK Download and Installation
| Capability | SDKMAN | jEnv | JetTUI |
|---|---|---|---|
| Downloads JDK for you | Supported | Not supported | Not supported |
| Downloads Maven for you | Supported | Not supported | Not supported |
| Manages non-JVM tools | Supported (Go, Gradle, etc.) | Not supported | Not supported |
SDKMAN dominates this category. It has its own source repository; one command downloads and installs. No need to hunt for packages on official websites. jEnv and JetTUI both require you to install JDKs yourself; they only manage "switching."
If you frequently need to try different JDK versions, SDKMAN is the most convenient to install.
Dimension 5: Switch Persistence
| Dimension | SDKMAN | jEnv | JetTUI |
|---|---|---|---|
| Takes effect in current shell | Yes | Yes | Yes |
| Writes to system environment variables | Via sdk default |
Via jenv global |
Directly writes JAVA_HOME / PATH |
| Persists in new terminals | Yes | Yes | Yes |
All three can persist settings, but the methods differ. SDKMAN and jEnv manage it through their own mechanisms; JetTUI directly writes to Windows user environment variables.
Dimension 6: Additional Capabilities
| Capability | SDKMAN | jEnv | JetTUI |
|---|---|---|---|
| Compile project | None | None | F2 mvn install |
| Start/stop Spring Boot services | None | None | F1 service management + separate logs |
| Package | None | None | F3 mvn package |
| JDWP debugging | None | None | Auto-assigns port |
| Manage Maven versions | Supported | Not supported | Supported (F4) |
JetTUI dominates this category. SDKMAN and jEnv only manage version switching. After switching, you still need to open a terminal yourself to compile, start services, and package. JetTUI consolidates all of this into a single interface.
4. Three Tools, Three Philosophies
With the comparison done, let's talk about the essence.
SDKMAN's philosophy is "I'll handle it for you." Download, install, switch—all in one go. You don't need to worry about where to download the JDK from or where to install it. The trade-off is that it only supports Unix-like systems; Windows users can't use the native version.
jEnv's philosophy is "I only handle switching; you handle the rest yourself." You install the JDK yourself; I help you switch versions. And the switching is particularly fine-grained—global, directory, and shell, three levels. The trade-off is limited functionality; compiling, starting, stopping, and packaging are none of my business.
JetTUI's philosophy is "switching versions is just something you do along the way." You were already going to compile, start services, and package; switching versions is just one part of that. F4 sits between F1, F2, and F3—press it when you need it, and it stays out of the way when you don't. The trade-off is it doesn't download JDKs for you, and directory-level automatic switching isn't available yet.
5. Which One Should You Choose?
Don't agonize over it; just find your match.
You're a macOS / Linux user who frequently tries new JDK versions → Choose SDKMAN
Download and install in one go. sdk install java 21.0.2-tem and you're done. No need to hunt for packages on official websites.
You have many projects, each needing a different JDK, and want automatic switching when entering a directory → Choose jEnv
Set jenv local 17 once, and from then on, entering that directory automatically switches. No need to manually switch every time.
You're a Windows user, fed up with changing environment variables → Choose JetTUI
Native Windows support. Enter a path, click a button, and environment variables are set. You can also compile, start/stop services, and package on the side.
You want all three → You can combine them
SDKMAN to install JDKs + jEnv to manage directory-level switching + JetTUI to manage compiling, starting, and stopping. The three don't conflict; each handles its own part.
But honestly, most people only need one. Pick the one that best addresses your pain point.
6. A Final Summary Table
| Dimension | SDKMAN | jEnv | JetTUI |
|---|---|---|---|
| Platform | Unix-like | Unix-like | Windows native |
| Operation | Command line | Command line | TUI with mouse |
| Download & install JDK | Supported | Not supported | Not supported |
| Directory-level auto-switch | Not supported | Supported | Not supported |
| Switch Maven versions | Supported | Not supported | Supported |
| Compile, start/stop, package | None | None | All included |
| Persistence | Supported | Supported | Writes system env vars |
| Manage non-JVM tools | Supported | Not supported | Not supported |
| Learning curve | Medium | Medium | Low |
There is no best tool, only the most suitable tool. Your platform, your habits, and your needs determine which one you choose.
SDKMAN Official Site: https://sdkman.io
jEnv Official Site: https://www.jenv.be
JetTUI Project Address: https://github.com/GengMS/JetTUI
JetTUI Online Demo: https://gengms.github.io/JetTUI
WeChat Official Account: 极客悟道
Which one are you using? Let's chat in the comments.
Top 2 of 6 from juejin.cn, machine-translated. The original thread is authoritative.
Who on earth is still switching versions manually? Isn't version switching built into every dev tool? AI can just access it via the full path too.
But if you just want to switch a version, why install an extra dev tool? And most dev tools only take effect inside the tool itself, not on the command line.
You mean you just install a JDK and don't do any development?
The directory-level switching comparison is clear.