I’m new to linux. I’m seeing a bash command (is that even the right term?) that sets JAVA_HOME environment variable at the prompt:
export JAVA_HOME =$(readlink -f /usr/bin/java |sed "s:bin/java::")
I know what the command inside $() does. But what is the $() for? It failed if I didn’t include it.
Obviously googling $() doesn’t work very well.
It’s used to get the output of the
readlinkcommand. For example: