Try the "export" plugin:

jenv enable-plugin export

You can check the Export plugin section in Readme.md at the jEnv Github repo (https://github.com/gcuisinier/jenv)

Answer from kimbaudi on Stack Overflow
🌐
GitHub
github.com › jenv › jenv
GitHub - jenv/jenv: Manage your Java environment · GitHub
Where multiple versions are set, the highest priority setting as above takes effect. For example if the global version was 17 and the shell version was 11, 11 would be used. Use jenv global VERSION to set a global, default Java version:
Starred by 6.6K users
Forked by 398 users
Languages   Shell 99.0% | Dockerfile 1.0%
🌐
Jenv
jenv.be
jEnv - Manage your Java environment
$ jenv versions system oracle64-1.6.0.39 * oracle64-1.7.0.11 (set by /Users/hikage/.jenv/version)
🌐
Medium
medium.com › javarevisited › manage-java-versions-with-jenv-6b8228552661
Manage Java Versions with jEnv. Master your Java Environment | by Jayson GCS | Javarevisited | Medium
September 11, 2023 - Navigate to the ../Home sub-directory and add that path to jEnv. jenv add /opt/homebrew/Cellar/openjdk@17/17.0.8.1/libexec/openjdk.jdk/Contents/Home/ ... Verify that all the intended versions are correctly added to jEnv.
🌐
Baeldung
baeldung.com › home › java › managing multiple jdk installations with jenv
Managing Multiple JDK Installations With jEnv | Baeldung
May 2, 2025 - This command sets the local JDK in the ~/baeldung-project directory. Setting the local JDK basically creates a file called .java-version in the current directory. The file contains the local JDK version “1.8″ which we have set.
🌐
Rob Allen
akrabat.com › using-jenv-to-select-java-version-on-macos
Using jenv to select Java version on macOS – Rob Allen
December 2, 2020 - $ jenv versions * system (set by /Users/rob/.jenv/version) 1.8 1.8.0.275 12 12.0 12.0.2 15 15.0 15.0.1 openjdk64-1.8.0.275 openjdk64-12.0.2 oracle64-15.0.1
🌐
GitHub
github.com › FelixSelter › JEnv-for-Windows
GitHub - FelixSelter/JEnv-for-Windows: Change your current Java version with one line · GitHub
This will set your JAVA_HOME for the current shell and ensures that tools like maven work properly · Add a new Java environment (requires absolute path) jenv add <name> <path> Example: jenv add jdk15 D:\Programme\Java\jdk-15.0.1 · Change your java version for the current session jenv use <name> Example: jenv use jdk15 Environment var for scripting: ---PowerShell: $ENV:JENVUSE="jdk17" ---CMD/BATCH: set "JENVUSE=jdk17"
Starred by 916 users
Forked by 106 users
Languages   PowerShell 97.1% | Batchfile 2.9%
🌐
Bring
developer.bring.com › blog › configuring-jenv-the-right-way
Configuring jenv the right way – Bring Developer
July 27, 2018 - Type jenv versions on terminal. You would see something similar to this.. system (set by /Users/sujithsreekumar/.jenv/version) - 1.8 - 1.8.0.92 - 10.0 - 10.0.1 - 9.0 - 9.0.1 - oracle64-1.8.0.92 - oracle64-10.0.1 - oracle64-9.0.1
🌐
MungingData
mungingdata.com › java › jenv-multiple-versions-java
Running Multiple Versions of Java on MacOS with jenv - MungingData
List the Java virtual machines with ls -1 /Library/Java/JavaVirtualMachines. Add Java 8 to jenv with jenv add /Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home/. Set the global Java version on your computer with jenv global openjdk64-1.8.0.265.
Find elsewhere
🌐
Adam Gamboa G
blog.adamgamboa.dev › using-jenv-to-switch-jkd-versions
Using jEnv to switch JDK versions
December 24, 2021 - It might be very common to require ... projects or applications. One way to switch Java’s version is setting the JAVA_HOME env-var to the installation directory of the desire version. To help with that work jEnv is a tool that you must use....
🌐
Reflectoring
reflectoring.io › manage-jdks-with-jenv
Managing Multiple JDK Installations With jEnv
October 18, 2022 - To use the new JDK with jEnv, we need to tell jEnv where to find it. Let’s check first which versions of the JDK jEnv already knows about with the command jenv versions: * system (set by /home/tom/.jenv/version) 11 11.0 11.0.8 13 13.0 13.0.2 14 14.0 14.0.2 openjdk64-11.0.8 openjdk64-13.0.2 openjdk64-14.0.2
🌐
My Developer Journal
sunitc.dev › 2021 › 04 › 23 › how-to-run-multiple-java-version-in-your-local-environment-using-jenv
How To Run multiple Java Version in your local environment using JENV – My Developer Journal
April 23, 2021 - Can be configured by running command – jenv local <java-version> ... This command creates a file – .java-version in the given directory. So even if we come back to this directory later, it will use the same JDK version that we had set earlier.
🌐
Medium
medium.com › @oyvind.ahlstrom › setup-jenv-to-manage-multiple-java-environments-f1d896a31b5b
Setup jEnv to manage multiple Java environments | by Øyvind Ahlstrøm | Medium
January 30, 2020 - jEnv is a command line tool that assists you in switching between installed versions of Java. It sets your JAVA_HOME variable in your active shell. You can set Java version globally or locally. This tool can be great for your team.
🌐
Medium
medium.com › @pranesh7 › java-version-management-with-jenv-cc79357180c9
Java version management with jenv | by Pranesh Satghare | Medium
December 2, 2025 - jenv add /Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home jenv add /Library/Java/JavaVirtualMachines/openjdk-11.jdk/Contents/Home jenv add /Library/Java/JavaVirtualMachines/openjdk-17.jdk/Contents/Home ...
🌐
SitePoint
sitepoint.com › blog › java › how to run multiple versions of all your dev tools with jenv
How to Run Multiple Versions of All Your Dev Tools with Jenv — SitePoint
November 6, 2024 - To update Jenv to the latest version, you can use the git pull command from within the .jenv directory. This will pull the latest changes from the Jenv repository and update your local copy.
🌐
OSTechNix
ostechnix.com › home › command line utilities › how to manage multiple java versions with jenv on linux
How To Manage Multiple Java Versions With jEnv On Linux - OSTechNix
June 27, 2020 - Now check all available Java versions to jenv using command: ... * system (set by /home/ostechnix/.jenv/version) 13 13.0 13.0.3 14 14.0 14.0.1 openjdk64-13.0.3 openjdk64-14.0.1
🌐
Andrew Jones
andrew-jones.com › blog › managing-multiple-versions-of-java-on-os-x
Managing multiple versions of Java on OS X · Andrew Jones
September 10, 2014 - $ jenv local oracle64-1.6.0.65 ... Server VM (build 20.65-b04-462, mixed mode) You can set a default version using jenv global [version], and show the full path to the Java executable by running jenv which java....
🌐
They
they.es › posts › jenv-easily-manage-multiple-java-versions
JEnv - Easily Manage Multiple Java Versions
March 23, 2021 - As you can see, the system wide version of Java can be set in a file ~/.jenv/version.
🌐
Atevans
atevans.com › 2019 › 04 › 26 › jenv-and-java-versioning.html
atevans - Jenv and Java Versioning
April 26, 2019 - $ brew install jenv $ eval "$(jenv init - zsh)" $ jenv enable-plugin export $ jenv add $(/usr/libexec/java_home) $ jenv versions * system (set by /Users/andrewevans/.jenv/version) 12 openjdk64-12