04 March 2010

Great ad

"Today's my Birthday" is a nice touch - it really got my attention. Kudos to Compassion for creating a great ad.

26 February 2010

A case for automated tests

In one minute, you can run one manual test or 100 automated tests. How would you prefer to spend that minute?

And what happens when you change some code? Run a few manual tests (three minutes)? Wouldn't you prefer to run 100 tests, grab some coffee, save a couple minutes, and be confident that your change didn't break anything else?

Mac OS X tip: open current Terminal path in Finder

$ open .

23 February 2010

Cisco VPN on Snow Leopard

Mac OS X Snow Leopard has VPN support built in, so you don't have to install the Cisco VPN client. (If there's one thing I dislike, it's installing unnecessary software.) This tutorial worked great for getting it set up - thanks to the author for posting it!

17 February 2010

Keyboard Shortcut for Maximizing a Window in XP

Alt, Space, X

This appears to be the only way to do it. I wish there were a quicker way, like Win + M does for minimize.

15 January 2010

SnakeYAML and Groovy

"Why aren’t more of us using YAML with Java and Groovy?"

From SnakeYAML and Groovy, my latest post on Inside the Machine.

29 December 2009

Running Linux commands from history

"Those who cannot remember the past are condemned to repeat it." - George Santayana, (c/o Wikipedia)

Sometimes I want to remember the past so I'm able to repeat it. (I'm always looking for ways to save a few keystrokes.) I just found out I can run Linux commands from my history with event designators like this:

$ !svn
svn co http://svn.example.com/svn/ExampleProject/trunk .


Typing !svn will run the last svn command I ran, which is much easier than retyping this:

$ svn co $s/ExampleProject/trunk .


($s is set to the root of my SVN repository to save some typing.)

Using !svn is also faster than using the up arrow to scroll back to my last svn command, as this often requires me to hit the up arrow several times until I find it, and sometimes I scroll right past it and it ends up taking a lot longer than it would for me to just retype it.

You can also use history to show the most recent commands you've executed, and then use the event designator (!N) to run the Nth command in your history:

$ history
...
636 svn log -l 10
637 svn up
638 history
$ !637
svn up
At revision 828.


Pipe history into grep for an abbreviated list.

You can see other useful history commands in this article.

(Update: I copied this post into Google Wave and made it public, so you can view, edit, and disuss this post in the public wave.)