Monthly Archives: April 2011

Twitter Harvest, 22 April

Happy Easter to all you humans out there.

Twitter Harvest, 20 April

We self-aggrandisingly  search Twitter, so you don’t want to:

Twitter Harvest, 18 April

Links every Monday, Wednesday and Friday, unless we forget.

Twitter harvest, 13 April

We selflessly search Twitter, so you don’t have to:

Jenkins talk in London, 31 May

Kohsuke Kawaguchi is doing a talk at Skills Matter, in London, on the 31st of May. You might know that he wrote Jenkins (nee Hudson). This should be a really informative talk, from someone who raised the game in Continuous Integration. I’m going to get there early to get a good seat. You need to register on the Skills Matter site, below. Get in quick.

Link

Tagged

#LondonCI gets a regular meeting

Londoners: Set the third Wednesday aside every month. We’ve got a regular meeting place and time, and now we need some speakers. I’ve started reaching out to some of the people in my address book who would make good speakers. We already have the first speaker. But please don’t let me dictate!

Email me at medic at build hyphen doctor dot com if you’d like to come and talk to a room full of Continuous Integration enthusiasts. I”m very happy to take requests for speakers as well.

I’m doing this because I want to meet up with everyone else in London who cares about doing Continuous Intergration right. If you do too, you’d be welcome.

Tagged ,

Inform or Accommodate?

Should you stop the build when someone breaks your formatting rules? Should you detect and fix them? There were two comments on the previous post: Oliver agreed, and Will didn’t:

Instead of raising errors when things like whitespace or tabs occur, why not just modify the file to correct it?

After some reflection I decided that you shouldn’t clean up on behalf of others. At best, you take away their feedback loop, at worst you compound the error. They need to know that something is wrong, so they have a chance to improve. But you can make tools to help them clean up their mess:

desc "Turn crap into gold"
task :midas do
  Dir["public/**/*.js"].each do |f|
    next if f.match(/^lib|resources/)
    sh "sed -i '' 's/  /  /g' #{f}"
    sh "sed -i '' 's/ $//' #{f}"
  end
end

Zero tolerance

This has been surprisingly useful at keeping my JS code clean.


desc "Check for tabs and trailing spaces"
task :crapcheck do
  Dir["public/**/*.js"].each do |f|
    next if f.match(/^lib|resources/)
    text = File.read(f)
    raise "Tabs found in #{f}" if text.match(/t/)
    raise "Trailing spaces found in #{f}" if text.match(/ $|    $/)
  end
end

The tab check is useful because I hate them, and they mess with JSLint; the trailing spaces mess up my diffs. Take that.

Tagged