I\'ve never worked with Maven before and I am following the instructions here. When I run the command
mvn integration-test -Pamp-to-war
It
Here's my automatic solution...
This will follow your javac
executable's symlink (setup by yum
and/or alternatives --config java
) backwards to find the JAVA_HOME
. (Toss this in your in your /etc/profile
):
export JAVA_HOME=$(readlink -f /usr/bin/javac | sed 's:/bin/javac$::')
If you wanted a stable path (refreshed on boot) launch something like this:
export JAVA_HOME=$(readlink -f /usr/bin/javac | sed 's:/bin/javac$::')
ln -sfn "${JAVA_HOME}" /usr/lib/jvm/jdk-current
I'm kinda shocked the latter still isn't baked into alternatives
.