Dan Cheail, Unplugged.

Given that Dan once ran RubySource and I’d already put a face to the name at one RORO meeting a couple of weeks earlier, it was stellar to actually get to know him better over the weekend. Additionally, I felt the title of Unplugged was justified, as he was playing acoustic guitar through the weekend. He’s as friendly as he is tall, which is taller than average, so he was happy to answer some questions for us!

Tell us a some things about yourself, Dan.

I started programming using BASIC when I was six, I sort of progressed from there through basic C, Pascal, Visual Basic, until I discovered the web in about ’95 and thought “right, this is for me”. Started building static websites, learned about PHP in 1999 and then discovered Ruby about five years ago. I’ve been writing code most of my life and it appears to be something I’m good at, so I decided to make a career out of it.

More specifically, how long have you been working on Ruby/Ruby on Rails projects for?

About four to five years, I remember checking out one of the first beta releases of Rails—0.8 or something like that—thinking that it was pretty cool, then proceeding to go off and try and implement the cool parts of it in PHP. I then realized that I would probably be better off just using Rails directly. So I sat down, learned Rails, and haven’t looked back since.

You gave some insight before, but what other languages have you been deeply involved with?

PHP, I spent five years as a PHP developer, it was probably the best stuff that I had access to at the time, I got a lot done with it. Before that, HTML and CSS, I’ve been using CSS since it was first made available in IE3. I remember when Netscape 1.2 came out with background images and I was shocked at how cool it was. Around that time, I was also doing some Visual Basic when I was at school. And before that I taught myself C and BASIC, a bit of Pascal for school, so a bit of everything.

What’s your favorite thing about anything Ruby/Ruby on Rails? Something that compels you to want to develop in it.

I really just like Ruby syntax. Ruby syntax and the Duck Typing aspect of it. It’s a very descriptive language. It’s a really strange thing to be excited about, and it’s something I say a lot, but Ruby lets me express myself the way my brain thinks, I don’t have to rethink things to code Ruby. Ideas tend to go directly from my brain through the keyboard and it works. The way I think, the way I attack problems, Ruby lets me do it naturally without having to go back and having to think about syntax or artificial constructs. It really seems to get me. Considering I spent over nine hours a day working in it, I need to enjoy it. It makes it pleasurable and lot easier to write code, as opposed to a lot of other languages I’ve had to use over the years. Ruby is a wonderful thing.

One of the things I want to document for aspiring Ruby developers, are there any big realizations you came across when you were learning Ruby, that would help others learning too?

There’s a couple of things. The first one was understanding Blocks and Lambdas, and the concept of anonymous functions and the meta programming that goes into that, and the fact that with Ruby, you can call code in places that you can’t in other languages… getting exactly how that worked in Ruby was an eye opener. The concrete example of that is understanding how the `has_many` and `belongs_to` calls actually work behind the scenes. Realizing that they weren’t just magic, it was actually calling methods within the class, on the class itself, rather than the instance. Understanding that was a huge leap forward, conceptually.

As well as the Duck Typing aspect, the fact that I can send a message to anything and I don’t need to worry about what it is, I just need to worry about whether or not it will respond to that message or not. And the flexibility that that actually provides. It allows me to write some smarter code, which I like to take great advantage of in what I do.

Free book: Jump Start HTML5 Basics

Grab a free copy of one our latest ebooks! Packed with hints and tips on HTML5's most powerful new features.

  • gigi

    A few thoughts and questions I always wanted to share and ask

    1) Back in 2004 (more or less) we were told that PHP couldn’t be used to build complex Framework nor other stuff such as ActiveRecord.
    Turned out it wasn’t true and also turned out that you can happily live without both.

    2) Then we were told, Ruby was the golden tool to implement stuff like Twitter.
    We all know how it ended (http://www.artima.com/scalazine/articles/twitter_on_scala.html) and personally I remember a lot of way more colored comments on the topic of ruby and performance at the time it happened.

    3) Then we had Zed Shaw (well entitled, I believe) opinions on Rails and Ruby community in general.

    4) Today, we have both PHP and Ruby on the inevitable(?) declining path of dynamically typed languages.
    But still every article on Ruby kicks off telling the world how much PHP sucks.
    The funny thing is that all these articles still run on PHP software of some kind.
    Be it a blog or cms.

    5) And here are the questions:
    – when ruby community is ready to propose itself and its achievements without very questionable comparisons and unproved bold statements?
    – when is this blog ready to migrate to rails or any other ruby solution? (I’m still reading wp every where in the source…tell me if I am wrong)

    p.s.
    Don’t reply telling me that I don’t know how much work it will need.
    Because this would prove that you are still well-served by the software you are using now and that a migration would
    be useless and not worth the effort. Basically the opposite of what you are telling us in every post.