.zshrc: command not found: jenv

Viewed 4103

I recently followed the steps to install jENV and Corretto-8. Unfortunately now whenever I open a new terminal I see the following:

Last login: XXXXXXX
/Users/username/.zshrc: command not found: jenv
/Users/username/.zshrc: command not found: jenv

Does anyone know how to fix this? I am truly at a loss.

1 Answers

This problem is likely occurring because jenv has not been added to your PATH before jenv init runs. Look at your .zshrc file and ensure the jenv section looks like this

export PATH="$HOME/.jenv/bin:$PATH"
eval "$(jenv init -)"

Also, be sure that you don't have multiple jenv sections since the installation instructions for Zsh are not re-runnable. If you accidentally ran the instructions for Zsh twice, you will find two jenv sections at the end of your .zshrc file and you should delete one of them.

Related