Craig Rowe

Techlead / Developer

30th April 2011

Last night I dreamt something existed that didn't..

Part of my role at Headscape has included looking at our development processes/practices. There's a blog in this (and it's coming soon), but as a brief teaser to that:

I'm using Cruise Control.Net to automate MSBUILD builds from our source control provider. Originally this was happening on a regular interval... but that's just annoying (if you get annoyed by such things) and led to waiting to see if it had built, or worse just force building anyway. Luckily Github and CodebaseHQ both have post commit/push hook mechanisms that we can take advantage of.

As you'd expect these processes post some data to a url of your choice when a push is received for a particular repository.

  • Great Stuff: I can simply post to a url to build from
  • Not so great stuff: I have no control over the hook other than the url it goes to

So, taking codebasehq as an example the post data they provide is json (as listed in their own repo). This is fantastic but the notification centre itself only allows creation of notifications to the project level, not repository level. So the repository name has to come from the post data itself (if I wish to build the CCNet project with the same name) i.e. I cannot use the url alone to identify the repository.

To join these two tools together I ended up making a small Application that could accept the post from Codebase and essentially forward it on to the appropriate CCNet build request. And so CIBridge came into existance, leading to the following workflow:

Commit Locally -> Push to Codebase -> Codebase Notification notifies CIBridge -> CIBridge forces a CCNet Build -> CCNet publishes the site

A better way?

Ok, so what I thought might be cool.. is customisable posts from these hosted source control providers. Something along the lines of a screen that allows you to build up a list of post variable 'templates' with keywords used to be replaced by the hook info during generation of the post.

So I could, for example, say 'I want one form variable called 'Repository' with the contents { name: %REPO_NAME% }' (where repo name is replaced by the repo that caused the notification).

In this way I could use the hosted source code provider directly, without the need for the bridge, nor for specific support from my current or future build server.

Am I missing something?

CIBrdige was a quick fix to get it running. Is there a better way?


Other Recent Posts

WP7 vs iPhone(16th February 2012)

Ok so if you follow me on twitter you may know that towards the end of last year I took part in 'Alphalabs'. Organised by onedotzero this was a competition aimed at encouraging developers and artists to work together on the Lumia 800 platform. …

Cargowire has a new design(5th February 2012)

Apparently doodling can be good for you. Although when I do it, it's not so good for Ed Merritt.…

Why you should try to be a middle class developer(16th August 2011)

You may not know this but this blog has been xml based since its inception (in fact there's a longstanding, not yet achieved, task to 'replace' it with a 'better' persistant storage mechanism -- clearly I must agree then, that the perfect is the enemy of the good). But anyway... don't worry. I'm not about to do anotherblogaboutxml.…

Falling out of Kindle love(10th July 2011)

While reading a book the other day (C# in depth if you're interested... I'd recommend it to all you .net lovers out there.. yes you.. both of you) I suddenly realised something. I was holding a book.…

SXSW 2011: The tale of the lost man points(10th March 2011)

So we're here... just, but with far less man points than we started... to be fair I think I've lost out to Ryan on this one