Update: Here’s a discussion of this post on Reddit, and here is a French translation.

I’m a developer. Here’s the graph of my open source contributions on GitHub for the last 12 months:

While I also do some open source in my spare time, the vast majority of those green dots happen during my work at the Government Digital Service (GDS), a team inside the UK Cabinet Office.

I’m not some special case in my team – if you look at GDS’s GitHub organisation, you’ll see loads of code there. Better still, our work doesn’t just happen at the fringes of government IT – we’re responsible for the GOV.UK website, which is the UK central government’s main publishing platform and the front door to all government transactions.

One point where I have perhaps exaggerated: as James Stewart, one of GDS’s technical architects, points out, what GDS does is actually “coding in the open”, rather than “open source” – this means that GDS makes the source available under an OSS license, but doesn’t support or build communities around it. In any case, even “coding in the open” is awesome for a number of reasons.

fairness towards the taxpayer

Government source should be open – after all, if the code was written on the taxpayer’s dime, it’s only fair that the taxpayer gets the code in return. Interestingly, criterion 15 in the recently published Digital by Default Service Standard should institutionalise this and ensure that all future UK government projects will be mandated to open up their source by default:

Make all new source code open and reusable, and publish it under appropriate licences (or have provided a convincing explanation of why this cannot be done for specific subsets of the source code)

fairness towards the OSS community

We use open-source languages and frameworks (most of GOV.UK is written in ruby and scala), open source web servers, manage our source and configuration using open source tools (git and puppet), and deploy onto open source operating systems (running linux). It’s only fair that we give back.

transparency

Having GDS’s code on GitHub makes my life as a GDS dev easier. If I need to integrate with, reuse or extend another GDS component, it’s just a few clicks in the browser or quickly cloning the repo.

The transparency also benefits those outside of GDS. Want to the rules for the state pension calculator? Just look at its source. Found a bug with the bank holidays page? You can submit a pull request to fix it.

I know of companies that have internal open source programs, and that’s definitely a step in the right direction, but having pretty much everything available brings the ideal of collective code ownership that much closer.

As an added bonus, since all the hacks and shortcuts would be there for everyone to see, less corner cutting is a natural consequence.

reuse

While a fair amount of the code we write is solving problems unique to our domain, large parts of it is general, and could easily be adapted for in other central, state and local governments, or in the private sector. In fact, people are starting to do that already. What some good front-end code? Check this out. Want a government-grade single-sign-on system? Here you go. Want to build your own smart answers? Knock yourself out.

marketing

Coding in the open is great marketing for the GDS brand. When I tell other hackers that I do open source at work, eyebrows go up. I’ve heard people outside GDS refer to it as the “government startup”; open source clearly enhances the brand.

as a portfolio

For purely selfish reasons, it’s really nice to have a portfolio of my work, somewhere I can point people to for tangible proof of my (in?)ability to write ruby.

I wish more employers did this (and not just in the public sector) – if yours doesn’t, perhaps the reasons above can help convince them to change their mind?