Advertisement for 'HTerm, The Graphical Terminal'

In 2007, Haskell began to experience some real growth; one of the new users was myself. The old ways of individual distribution with Autotools configuration & installation weren’t state of the distribution art; the shining example was Perl’s CPAN. At about that time, Duncan Coutts and a few others proposed something similar called Cabal.1

I was looking around for a way to help out the Haskell community, and was impressed by the idea of Cabal. It would make it easier for Linux distributions to package Haskell libraries & executables (and has - witness how Arch Linux’s distro packages are automatically generated from the Cabal packages). But more importantly, by making dependencies easier for authors to rely on (or eventually automatically installable thanks to cabal-install), Cabal would discourage duplication and encourage splitting out libraries. An application like the Gitit wiki, with its >40 dependencies, would simply be unthinkable. It may be hard for Haskellers who started after 2009 to believe, but applications would often keep in the source repository copies of whatever libraries they needed - if the libraries weren’t simply copied directly into the application’s source code. (In a case I remember because I did much of the work to fix it, Darcs used a primitive local version of bytestring for years after bytestring’s release.)

Unfortunately, Cabal’s uptake struck me as slow. My belief seems to be supported by the upload log. In 2006, there are 46 uploads by 5 people; the uploads are mostly of the boot libraries distributed with GHC like mtl or network or unix. 2007 shows a much better uptake, with 586 uploads (not 586 packages, since many packages had multiple versions uploaded) by 100 people. (I was responsible for 4 uploads.)

So I decided to spend most of my time Cabalizing packages or nagging maintainers to upload. Ultimately I did 150 uploads in 2008. (A discussion of my Haskell and uploading activities can be found on the about me page.) In total, Hackage saw 2307 uploads by 250 people. In 2009, there were 3671 uploads by 391 people; in 2010, there were 5174 uploads by 490 people. Long story short, Cabal has decisively defeated Autotools in the Haskell universe, and is the standard; the only holdouts are legacy projects too complex to Cabalize (like GHC) or refuseniks (like David Roundy and Jon Meachem). I flatter myself that my work may have sped up Cabal adoption & development.

As you can imagine, I ran into many Cabal limitations and bugs as I bravely went where no Cabalist went before, but most of them have since been fixed. I also worked on some very old code (one game dated back to 1997 or so) and learned more than I wanted to about how old Haskell code could bitrot.

I learned (I hope) some good practices that would help reduce bitrot. In order of importance, they were:


  1. Strictly speaking, Cabal was first proposed in 2003 and a paper published in 2005, but 2007 was when there was running code that could credibly be the sole method of installation, and not an experimental alternative which one might use in parallel with Autotools.

  2. Mark Pilgrim, Freedom 0; he is quoting/paraphrasing Matthew Thomas

  3. For an explanation of this task, and how that monad stuff works, see Run Length Encoding