Skip to content

Programming · Games · Life outdoors

JAVA_CMD for lein

Sometimes you need to configure lein  to use a custom JDK. On Linux, set the environment variable JAVA_CMD  to point to the java  executable you want lein  to use.

For example, you might add the following lines to your .bash_profile

#used by LEIN
JAVA_CMD=$HOME/installs/jdk-11.0.10+8/bin/java
export JAVA_CMD

Once you update your bash profile, you can start using your configuration by using the following command.

source ~/.bash_profile