Why I love Ruby

I’ve been a fan of the Ruby language since I was first introduced to Ruby on Rails back in 2005. While I was learning both Rails and Ruby, it quickly became apparent that all the awesome-ness of the former would never have been possible without the latter; what makes Rails great is Ruby, and Ruby would almost certainly still be an obscure and under-appreciated language had it not been for Rails. Ruby is a remarkably beautiful language, and I love working with it.

Freedom to hang ourselves

To me, and infinitely more prominent people like David Heinemeier Hansson, Ruby is very much about freedom. Freedom to shape the language to suit our purpose and fulfill our needs. Ruby will likely never feel old or outdated, because we are free to change it, to create our own versions of the language. The killer feature is that we can do this without needing to change the Ruby source and compiling a new version of the language – we can do it from within our own frameworks and applications.

This is the point where many die-hard supporters of statically typed, compiled languages usually stop and go “What? That cannot possibly be safe? How do you guarantee that X does what X usually does?” The answer is that you don’t, but why do you need it to? As long as you don’t fundamentally alter (which I would interject might be correct in some scenarios) built-in types and so on, what is the problem of changing the behavior to better suit the tasks at hand? Are you really willing to trade freedom for security? Even if that freedom meant you could create beautiful code and focus more solving the tasks at hand, as opposed to having “guaranteed” runtime behavior, type safety etc? When was the last time static type checking saved your day? As DHH himself said in his keynote at RubyConf 2010 as a response to the oft cited “Just enough rope to hang yourself with” comment; “Should we outlaw rope, just because people can hang themselves with it?”

There are things you can do in Ruby, changes that fundamentally alter how the language itself works, that you probably shouldn’t do, but should the language really prevent you from doing it, or should you learn on your own? Personally, I’m all for the latter – learning through experience.

It’s also about the people

The freedom Ruby provides me with, is the biggest reason I love it as much as I do, but Ruby also has a fantastic community. A community that continues to innovate and develop fantastic services such as Heroku, and projects such as Sinatra. There is a feeling in the Ruby community that everyone is free to innovate and create the next big thing. Sure, there are some bad eggs in the batch and it’s not always just peachy, but it’s still by far the most inspiring and friendly community I’ve ever felt I’ve been a part of.