• Overview
    Key features
    • Observability
    • Auto-scaling
    • Multi-framework
    • Security
    Frameworks
    • Django
    • Next.js
    • Drupal
    • WordPress
    • Symfony
    • Magento
    • See all frameworks
    Languages
    • PHP
    • Python
    • Node.js
    • Ruby
    • Java
    • Go
  • Industries
    • Consumer Goods
    • Media/Entertainment
    • Higher Education
    • Government
    • Ecommerce
  • Pricing
  • Overview
    Featured articles
    • Switching to Platform.sh can help IT/DevOps organizations drive 219% ROI
    • Organizations, the ultimate way to manage your users and projects
  • Support
  • Docs
  • Login
  • Request a demo
  • Free Trial
Blog
Thumbnail

Give the gift of Ruby this season

ruby
18 December, 2018
Ori Pekelman
Ori Pekelman
Chief Strategy Officer

We've had Ruby 2.5 in beta for a while now, although we haven't talked about it much. It's been working wonderfully, though, and rubies make great holiday gifts for the geologists in your life. So it's time to go General Availability!

What gems does this version have?

Ruby 2.5 has a bunch of very cool language features, and probably the most interesting is yield_self; it rather resembles the pipe operator from Elixir, and pipes are cool. Method chaining is also a great way to simplify syntax, and this basically gives you a more general approach then the .map and .select we're already used to.

Also nice in day-to-day life "rescue in do blocks" it reduces clutter and unnecessary indentation.

things.each do |thing|
  thing.evil_method_that_bombs
rescue VeryBadError => exception
  p exception
  next
end

Short and sweet.

Is it expensive like a real ruby?

Not at all! As always, migrating your Ruby apps is as easy as changing a single character in your .platform.app.yaml file:

so instead of :

type: "ruby:2.4"

Go for the brand new:

type: "ruby:2.5"

Create a branch, push, and test that everything works on your development environment. If it all checks out, merge. Now you're running Ruby 2.5 in production. (And you probably just gained around 10% performance, too. Go you!)

A number of Ruby applications already require 2.5 or higher, such as the latest Discourse betas. So if this is your jam...go forth and deploy.

Get the latest Platform.sh news and resources
Subscribe

Related Content

Platform.sh is always one step ahead: Announcing PostgreSQL 15, Python 3.11, and Ruby 3.2 for our users

Platform.sh is always one step ahead: Announcing PostgreSQL 15, Python 3.11, and Ruby 3.2 for our users

Company
AboutSecurity and complianceTrust CenterCareersPressContact us
Thank you for subscribing!
  •  
Field required
Leader Winter 2023
System StatusPrivacyTerms of ServiceImpressumWCAG ComplianceAcceptable Use PolicyManage your cookie preferencesReport a security issue
© 2024 Platform.sh. All rights reserved.
Supported by Horizon 2020's SME Instrument - European Commission 🇪🇺