Tuesday, April 24, 2007

Ping Pong Programming

Ping Pong Programming

Aim: To get your pair to do the hard work.

Setup: The game begins with a failing test. Players take turns...

Turns: You have 3 options

a/ Make the failing test pass
b/ Do any refactoring you can see
c/ Write or Uncomment a new failing test

a/ Comment out the failing test
b/ Write a simpler failing test

a/ Comment out the failing test
b/ Refactor to simplify the code
c/ Write or Uncomment a failing test

Hints: If your turn is longer than 3 minutes try option 2 or 3

Notes: Give this a go and notice how frequently you change drivers. Great when you have a pair that hog the keyboard.

Sunday, April 22, 2007

Freelancing on Rails

If you are freelancing as a software developer and especially if you are focused on rails, you should check out Craig Ambrose's podcast series.

I have had the pleasure to work with Craig at both Torus Games and Open Windows, and always find him insightful, pragmatic, and a pleasure to work with.

Check it out at http://www.craigambrose.com/podcasts

Friday, April 06, 2007

Hobo on Rails

Hobo looks great! It's a web framework built on top of Rails. It's structured as a plugin, so you can use as much or as little of it as you want.

I recommend checking out the screencasts to get a good overview of how this all works. I must say, I'm impressed.

I love the way it simplifies updating of several parts of a page with a single ajax call. Their solutions seems to be to tag parts of the page, then in the ajax call pass a list of parts that will need to be refreshed. The page is therefore telling the controller what parts to spit back, so the controller doesn't need to know the 'current page'. I'll have to look into exactly how this works.

I was also very impressed by DRYML, their templating system. It's just so simple! You define custom tags which is equivalent of defining functions, so they have a list of parameters and a body. When calling the tag you can pass in the details as the parameters. There is a nice concept of a context object for evaluation of any part of the DRYML, which simplifies the code in the tags too.

[It still find it amusing when people proposing their framework as the fastest way to develop a web app use php for their own site. What's with that?]

GitHub Projects