I have been trying to install React Native into my Mac. In the installation docs, it requires Ruby version of 2.7.6 have been to be installed.
I have installed a new Ruby version using rbenv manager and it was successful. But now I cannot switch my machine to new Ruby version. Any help will be highly appreciated.
Thanks!
2
Answers
You have to set the version for the directory where your react project is. You can do this with:
This creates a file called
.ruby-version
in the directory, which tells rbenv what version of Ruby to use.This is all visible in the README of rbenv.
You can have a look at this solution
Use the below command to change your ruby version:
You can find this from rbenv Official Github Repo