0

I'm having difficulty getting rbenv to change my ruby version. I've reviewed the question here but still struggling: rbenv not changing ruby version

Then ran rbenv init after install, then ran env | grep PATH but don't see any reference to rbenv.

THe documentation (https://github.com/rbenv/rbenv#how-rbenv-hooks-into-your-shell) states that rbenv init adds the necessary text to your PATH automatically.

I am using zsh. I don't know how to edit my PATH file. If someone provides an answer on how to add what I need to PATH, please be explicit with instructions to do so.

Caleb
  • 91
  • 10
  • 2
    There is no such thing as a _PATH file_. You set up your PATH in the zsh initialization files, typically .zshrc. AFIK, you can copy & paste the output of `rbenv init - zsh` to an appropriate plac of your .zshrc. – user1934428 Jan 13 '23 at 08:18
  • `rbenv init` DOES NOT adds the necessary text to your PATH automatically, they show you how to do it, you can use `nano` or vscode if you have installed to insert it, so `nano ~/.zshrc` or `code ~/.zshrc` (or `~/.bashrc` if you are not using zsh), you usually want to add the lines given by the command before any path is set, so the first lines will be the safest if you are not sure how these files work – saviu-u Jan 13 '23 at 14:41
  • thank you! I actually needed to move the additional lines to the end of my PATH, then it worked. @Alex I used Homebrew. – Caleb Jan 13 '23 at 17:57

0 Answers0