I installed JDK and added path variable but still i am facing -> zsh : command not found: jdk in macOS

huangapple go评论75阅读模式
英文:

I installed JDK and added path variable but still i am facing -> zsh : command not found: jdk in macOS

问题

我尝试了给这个路径变量,但似乎没有起作用

```export $JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk-11.0.8.jdk/Contents/Home```

然后我尝试了这个,似乎起作用了

```export JAVA_HOME=$(/usr/libexec/java_home)```

但仍然遇到了jdk命令未找到的问题

基本上,我正在尝试安装chromedriver,使用以下命令

```sudo apt install chromium-chromedriver```

但我遇到了这个错误
英文:

enter image description here

I tried giving this path variable but didn't seem to work

export $JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk-11.0.8.jdk/Contents/Home

Then I tried this, and seem to work

export JAVA_HOME=$(/usr/libexec/java_home)

but still facing jdk command not found issue

Basically, I m trying to install chromedriver using

sudo apt install chromium-chromedriver

but I'm facing this error

答案1

得分: 1

jdk不是一个命令。您可能想要使用的基本命令是javac用于编译您的代码,以及java用于运行它。

英文:

jdk is not a command. The basic commands you probably want are javac to compile your code and java to run it.

huangapple
  • 本文由 发表于 2020年8月21日 18:59:29
  • 转载请务必保留本文链接:https://go.coder-hub.com/63521588.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定