
This week, I have decided to learn Ruby as a new programming language. I decided that since I am mainly a web developer, I should set up Ruby on Rails and go that route. For those that do not know, Ruby is the general language, and Rails is the web framework for Ruby. I found the install of both Ruby and Rails very straightforward and simple. Once I had both installed on my machine, I decided to checkout what Tekpub had in terms of learning Ruby on Rails. Tekpub is a website aimed at developers with video tutorials on various technologies (Ruby on Rails, ASP.NET MVC, jQuery, etc.). I started watching the first of a series showing Ruby on Rails. I was following the instructor (Rob Conery), and when he got to the section of installing a testing gem (kind of like a package in Java, or assembly in .Net) called Cucumber, I got messed up. It was working for him, but not me! I was like “What the frak!” Well it turns out all the way in the last video in the series, he goes and says that people have mentioned that the steps in the first video (the one I was at) did not work for them. He then goes and shows what he should have done, and yada yada yada. Well, in the end I got Cucumber to install correctly on my machine.
Once I got it installed correctly, I started playing a bit with Cucumber. It seems very interesting. Cucumber follows the concept of Behavior Driven Development. As it says in its website: “Cucumber lets software development teams describe how software should behave in plain text. The text is written in a business-readable domain-specific language and serves as documentation, automated tests, and development-aid – all rolled into one format”. I haven’t gotten too far into it, but once I do, I am sure I will share more about it.

It has been awhile since I wrote about my examination of what language to learn first after using .Net for years. I narrowed it to PHP, Perl, Python, Ruby, and Java. So far, I had gone over all but Java. The reason I did not do Java is because I felt that the examination code I would have written in Java was basically C#. That would not have really brought anything new to light for me. That is not really attractive to me for a new language. I was now left with PHP, Perl, Python, and Ruby. I found that Perl was very cryptic in its syntax, PHP was just for web, and that Python and Ruby are very similar. I had Python and Ruby in the top two. Researching what people thought about the two languages, I found that Ruby had the advantage. Since I take what the development community thinks seriously, I have chosen to learn Ruby. I will probably try to learn Rails as well.
I have said in the past that I am anal. What I am not always is creative. I want to write a new application, but I just can’t think of what to create. I could be crazy and rewrite the web application we develop at work, but I am not that desperate. How about a help ticket system? How about a POS system? What else? I don’t know. I will have to think about this one…
Last Sunday I went over a list of possible programming languages to learn. It ended with me decided to learn all of them, but unsure as to what to learn first. I decided to go over each of them and figure out what I thought about them. How would I do this? What I have decided to do is see how complex it is to do the same thing in each language. What better to test out a language than to create a class? Wednesday, I went over the PHP implementation. Today is Ruby’s turn.
Ruby Class
class Person
def initialze(firstName, lastName, age)
@firstName = firstName
@lastName = lastName
@age = age
end
def IntroduceYourself
"Hello, my name is " + @firstName + " " + @lastName + ", and I am " + @age + " year(s) old."
end
end
Ruby Implementation
dan = Person.new("Dan", "Appleyard", 27)
puts dan.IntroduceYourself
My Thoughts
Rubys seems similar to Python. Since I liked Python, I like Ruby. At this point in my limited knowledge of these languages, I don’t really see the differences between Ruby and Python. My final examination will be that of Java.
I have been too busy today to mess around with Ruby. Will try tomorrow.