To install ufo via RubyGems.
gem install ufo
Ruby 3.0 and above is recommended.
The nice thing about this installation method is the standard way to install Ruby libraries and gems. It integrates with your existing Ruby installation. And you have the most control over the installation.
If you’re looking for Ruby installation help: Ruby Install docs.