faded picture of luke
a semi-random photo | click for the full photo gallery
click to browse photos
homepage navigation

Luke Melia

Capistrano and your shell

I’ve just started to use Capistrano to deploy my non-rails sites and ran into a bit of trouble. My web host for these sites is pair.com, and I’d already installed the subversion client there.

When trying to deploy using capistrano, I was getting a command failed RuntimeError as well as this odd line in my cap output:

** [out :: chi.pair.com] if: Expression Syntax.

I spent a bunch of time chasing down whether something about the command was wrong, perhaps the way it was calling date with the format. But it turns out that the problem was occuring becaue to my pair account user shell was set to csh and not bash. You can check this by running this command within a session on your pair account:

cat /etc/passwd | grep $USER

To set the shell, run the following (also on your pair account):

chsh -s bash

That was the only major issue I ran into. Deployment with capistrano is a beautiful thing!

Shaker proverb for software

I picked up a Shaker proverb from Ryan Davis at a recent nyc.rb meeting. It applies splendidly to software development:

If it is not useful or necessary, free yourself from imagining that you need to make it.

If it is useful and necessary, free yourself from imagining that you need to enhance it by adding what is not an integral part of its usefulness or necessity.

If it is both useful and necessary and you can recognize and eliminate what is not essential, then go ahead and make it as beautifully as you can.

– Shaker saying (“Shaker Built: The Form and Function of Shaker Architecture” (This origin is dubious)

Two keyboards, two mice

I finished my second day pairing with two keybords and two mice hooked up to the development station. This experiment was inspired an endorsement from Mike Hill at SD Expo. The hardest things about it have been letting go of the muscle memory/ritual of passing the keyboard, and establishing the unwritten rules of engagement for taking control. Overall, I like it. It moves a pairing session towards “show” rather than “tell”, and that tends to be more productive. Plus pace seems slightly faster because you’re eliminating the lulls of resituating the mouse and keyboard.

Try it and let me know what you think!

On Pairing Etiquette

Jeremy Miller (a recent transplant to New York… welcome, Jeremy!) shares a few Important Tips for Pairing Etiquette:

  1. If your a backseater, wait until the driver gets off the line of code to yell at him for a typo
  2. When you’re pairing, change your IM status to “Pairing with Bob” so your wife doesn’t IM you with embarassing terms of endearment.
  3. If you want me to pair with you, I really, really want you to have ReSharper & TestDriven.Net. VS2005 is basically naked without.

Here, here to number 3. I’d add that you need the TDD LiveTemplates for Resharper that Matt Berther put together or your team’s equivalent. Call me impatient, but why do I need to wait for you to type:

public void Test()

when you could have typed t and tab?

I’ll add some more pairing etiquette tips:

  • Don’t wear headphones. I think this would be obvious, but some people…
  • Don’t answer your cell phone while pairing unless it’s an emergency. Prefererably, turn off your ringer before we start.
  • Be conscientious about health issues if we’re sharing a keyboard. You don’t have to OCD crazy, just bring some common courtesy, and do stay home if you’re sick.
  • The more frequently we switch the driver/passenger role, the better. It keeps us both fresh and engaged.
  • Keep our workspace reasonably clean and clutter-free. Have some pen and paper and index cards handy.
  • When you’re the passenger, be responsible for keeping a mini todo list on paper. Sometimes it functions as a call stack, if you agree as a pair to follow a tangent, it’s important to remember where to come back to.
  • Finally, bring your “A game”. Pair programming crystallizes how few the productive hours in the day really are. Be healthy, well-rested and ready to commit completely to working together for the few hours we have.

Building a great XP team requires building trust and teamwork. Treating your pairing sessions and pairing partners respectfully is a great way to move toward that goal.

LukeMelia.com created 1999. ··· Luke Melia created 1976. ··· Live With Passion!
Luke Melia on software development freelance web development how to contact me Luke Melia, Software Developer letters and more from my travels photo gallery personal philosophy