Category Archive for 'Ruby'

irb: Learning Ruby Quick

Wednesday, October 17th, 2007

In my previous post I introduced the idea of using irb as a desktop calculator. If you are new to Ruby, however, using irb can have the side effect of teaching you Ruby. Everything you type in irb is a Ruby statement. The response you get from irb is the value Ruby returns from the […]

irb: The New Desktop Calculator

Thursday, October 11th, 2007

One of the things I love about Ruby is that it comes with irb. It is short for Interactive Ruby, and it is a command line tool to interact with an instance of the Ruby interpreter. To start it up just run irb from the command line (Interactive Ruby is a menu option in the […]

Moving Up on Mini-Scripting

Monday, September 10th, 2007

After my previous post on ad hoc scripting I had an example come up in my own work. I needed to search through some web logs for all hits in August to three servers from a pair of IP addresses. Below is the actual command line script I used, except I changed some identifying information […]

Method Aliasing and Aspect-Oriented Programming

Thursday, August 30th, 2007

One of the things that I have recently played with in Ruby is a sort of aspect-oriented programming. I say “sort of” because Ruby is not really an aspect-oriented language out of the box, but with some inconvenient constructs one can approach problems in this manner, using this mindset. I touched this because I am […]

From Vim to TextMate

Saturday, August 25th, 2007

Yesterday I switched from using Vim for all my code editing to TextMate. It is Mac only and costs €39 when I decide to register, but I really like how much easier it is to switch between more than two files and how it auto-terminates parentheses, logical statements, and HTML tags. This latter behavior should […]