This is a quick and dirty utility I put together for my own use, but maybe someone else will find it useful. It can take a project from a local Code Co-op installation and recreate the full history as a Bazaar repository.

To use it you need Code Co-op installed, along with its command-line tools which come as a separate installer. You also need Bazaar installed and in your path. Usage is simple – select a project from the dropdown list, enter the path to a new directory where you want the bzr repository created, and press the ‘Go’ button.
Getting It
You can download the binary version from http://ciarang.com/stuff/Coop2BZR-1.0.zip. The zip file contains a single exe file, which is all you need. If you want the source (C#), bizarrely it is hosted under git, and is here: http://projects.ciarang.com/p/Coop2BZR/.
Background
Reliable Software‘s Code Co-op is on the very short list of software I’ve been using for over a decade, and on another even shorter list of software that doesn’t get on my nerves on a regular basis. A distributed version control system (DVCS) long before such things were fashionable, there was a time when I would have said it was the best option available for source control. These days, for a small Windows-only development team it’s still an excellent choice, but version control systems have become a something of a commodity over the last few years and the best all-round choices (i.e. Git, Darcs, Bazaar, SVN, Mercurial) are open and cross-platform, the two main things Code Co-op is lacking.
Even so, the intention behind developing this is not so much migration as the need to deal with the following issues:
- Backup – I have an awful lot of old project history in Code Co-op. For archival purposes, I don’t want it stored in a proprietary format that I can’t access in ten years time when I want to look at it.
- Cross-platform development – Some of my projects that started out in Code Co-op as Windows-only have become cross-platform. They do need migrating, at least until I can make this a two-way bridge.
- Blame – Oddly, Code Co-op lacks a ‘blame’ feature. By exporting a project to a format that does have it, the necessary facilities can be accessed even though the project continues to be run in Code Co-op. I regularly spend longer figuring out the origin/history of a section of code than it took to write this whole utility, so was worth it for that alone.
Another question might be why Bazaar? No particular reason. As well as Code Co-op, I actively use SVN, Darcs and Bazaar, and very occasionally Git and Mercurial. In fact, thinking back, the real reason was that out of the box, Bazaar will handle files being added to and removed from the local tree without any additional commands, which made coding this a bit easier. The point is it doesn’t really matter which, because once the repository is in an open format there are plenty of ways to convert it to one of the others.
As mentioned above I intend, sooner or later, to turn this into a two-way bridge – if you’re interested in that, watch this space.

2 comments
Comments feed for this article
Trackback link: http://ciarang.com/posts/coop2bzr/trackback