![]() JAVA_HOME=” /usr/lib/jvm/jdk1.8.0_211" MAVEN_HOME=”/usr/share/maven” PATH=$PATH:$HOME/bin:$JAVA_HOME/bin:$MAVEN_HOME/bin export JAVA_HOME export MAVEN_HOME export PATH ![]() Add the following to the bottom of the doc. $ sudo vi ~/.bashrcĪnd Press ‘i’ to move into insert in vi-editor. Open the ~/.bashrc with vi-editor to append the following environment variables to the bottom. $ update-alternatives -list java $ update-alternatives -list javacġ1. Verify the setup by executing the following commands. Set the Java Location $ sudo update-alternatives -install "/usr/bin/java" "java" "/usr/lib/jvm/jdk1.8.0_211/bin/java" 0 $ sudo update-alternatives -install "/usr/bin/javac" "javac" "/usr/lib/jvm/jdk1.8.0_211/bin/javac" 0 $ sudo update-alternatives -set java /usr/lib/jvm/jdk1.8.0_211/bin/java $ sudo update-alternatives -set javac /usr/lib/jvm/jdk1.8.0_211/bin/javacġ0. Afterwards type (:wq!) and Press Enterĩ. Save the changes based on the editor opened - 8.1 If Nano - Ctrl + O and then Ctrl + X - 8.2 If Vi - Press Escape. The modified environment file must looks like following.
0 Comments
Leave a Reply. |