Installing Rails on M1 (native)

This time I’m going to detail how I installed Rails on a MacBook Air without Rosetta. Very simple and straightforward:

brew install ruby

As of February 2022, this gets you a native version of ruby ready to install rails. now, the version of ruby installed is `2.6.8`, so the latest version of rails cannot be installed.

You can check the latest version of rails supported according to the ruby you have on your system here:

[Ruby & Rails Compatibility Table - FastRuby.io | Rails Upgrade Service](https://www.fastruby.io/blog/ruby/rails/versions/compatibility-table.html)

In my case, the latest supported rails version is 6.1.x, so I’m going to install it with this command

sudo gem install rails -v 6.1.4.4

You can check all the rails available versions here

[All versions of rails](https://rubygems.org/gems/rails/versions)

That’s it. You want to make sure all the other requirements in the Rails Guides are ready too.

[Getting Started with Rails - Ruby on Rails Guides](https://guides.rubyonrails.org/getting_started.html)