When I'm trying to create a rails app using rails new a--name
command. it throws me this error saying I currently have 2.6.10
but when I find out the version I'm using ruby -v
it still gives me
ruby 2.7.5p203 (2021-11-24 revision f69aeb8314) [arm64-darwin22]
as expected. I'm using rbenv
(just to give you context) I tried finding the reason online but nothing really helped. any help on this would be really helpful.
Here is the screenshot of the list of my rbenv versions
and my ruby version
Thanks in Advance.
Ignoring racc-1.6.0 because its extensions are not built. Try: gem pristine racc --version 1.6.0
Ignoring racc-1.6.0 because its extensions are not built. Try: gem pristine racc --version 1.6.0
Rails 7 requires Ruby 2.7.0 or newer.
You're running
ruby 2.6.10p210 (2022-04-12 revision 67958) [universal.arm64e-darwin22]
Please upgrade to Ruby 2.7.0 or newer to continue.