A lengthy account of benmachine's forays into computer programming

Last updated 6th January 2012


The first form of code I ever learnt was HTML, since websites were The Thing in those days. In developing my skills, I somehow learnt of the existence of JavaScript and even more bizarrely decided it would be a good idea to learn said language. I was never any good at it but learning its basic constructs in a relatively simple environment set me up nicely to learn more powerful and interesting languages.

It seems it was about August 2006 that I got bored of my various Age of RTS games and started searching for something else to play with my friends. Browsing's games directory, I came across Tremulous, a free and open source shooter, though at the time I knew little of what it meant to be GPL, who the FSF were, or what a Finnish penguin had to do with the future of the computing industry. Tremulous was based on the Quake 3 source, which had recently been released under the terms of the GNU GPLv2, and Quake 3 (being now more than a decade old) had been written in good old C. This, coupled with a friend Bill's affinity with that selfsame language, began my attachment to the decades-old, bluntly unforgiving yet enchantingly powerful dialect.


Some time around the end of December or the new year, I learnt, from web tutorials and a couple of my friends (of whom I feel I must also mention Tim, who in addition to being a decent coder was and is a thoroughly decent chap), how to write simple C, followed inevitably by how to write complicated C. Applying my newfound knowledge to my favourite form of entertainment, I toyed with the Tremulous source with varying degrees of carelessness and irresponsibility over the next few months, producing largely cack with one or two genuinely useful contributions hidden amongst them. In the following August, around the first anniversary of my discovering the game, I joined the Mercenaries Guild, a group of players dedicated to being helpful and friendly and making a positive contribution to the community which had accumulated around an increasingly popular game. Their spirit of co-operation and responsibility helped beat a little sense into me, and soon afterwards I was credited in the commit logs for Tremulous' official source code repository for the first time.


In the year or so following, I improved those skills a great deal, while in the meantime Tim's heartwarming Perl bot, vurl, lent me a familiarity with the infamously write-only language with which I have always held at least one half of a love-hate relationship. Still preferring C for any application larger than a single file, I started two full projects and a plethora of little toys and tools, including my first foray into graphics through Allegro and SDL, while through some free webspace loaned by a most generous friend I developed my knowledge of HTML into a familiarity with PHP, and subsequently MySQL and CGI. In October, my hard work in Tremulous development was richly rewarded, as the lead developer, Timbo, PMed me asking me what password I'd like to use to commit to the official Tremulous SVN repository. Somewhere amongst fixing all the bugs I could get my hands on, I also started working on Project Euler, developing solutions to set problems through the use of simple and brief programs.


Of course, I had known for some time that skill in a single language, no matter how developed, doth not a good programmer make: near the end of 2008 I started work on my first Python project, a resurrection of the Adv_Dretch IRC bot for querying Tremulous servers, and close to the beginning of 2009 I ran through a Haskell tutorial. The latter impressed me a great deal as a mathematician as well as a programmer, and I took a keen interest in the community and development of the language. To whet my appetite, I wrote yet another IRC bot (at least my third), some SDL things, and assorted sillinesses. My Python was not entirely forgotten, however, and one of my few serious from-scratch projects, a reimplementation of the Tremulous master server, eventually went into live service.

Contact with Haskell, however, entirely spoiled me, and by the time I arrived at university I was converted, using other languages only by necessity. To some extent it still seems something of a niche language, lacking wide acceptance, in particular in the jobs market, but its community is more welcoming and helpful than any other I've met, and its fast pace of innovation and research keeps it consistently interesting.


Some time before January 2010 I started work on a larger Haskell project: a program for evaluating a Haskell expression step-by-step so that the mechanisms of pattern-matching and application and so forth can be observed. This eventually evolved into a CGI script as well as a command-line tool. Around late April I lost steam a little, although I continued work on the project on-and-off in the following months. In the meantime, my github account expanded from that first project to include some forks and four Hackage packages: haskell-src-meta, pointfree, applicative-quoters, and MaybeT-monads-tf. These are all essentially adoptions or adaptations of other people's work, but interesting nonetheless. I also contributed to th-lift, patched Cabal's user guide, and fixed typos in cabal-install.


My ability to program seriously went downhill somewhat as my university commitments really started absorbing my time. In the summer of 2011 I applied for a job somewhere using Erlang, so I briefly read learn you some erlang. It seems like most of the really difficult concepts from there, or at least from the first few chapters, have been “wow look at this functional programming technique”, so I reckon there's a gap in the market for a Erlang-for-haskellers tutorial, which would skip most of that and isolate the differences between the two.

I didn't take the job, though, so that project has been put on what I euphemistically call the Back Burner (alongside, admittedly, most everything else I do). I reverted back to Haskell, and as part of a different job dabbled in database programming with HSQL.

At some point I noticed MaybeT-monads-tf was redundant, since transformers and monads-tf between them provide the same functionality, and correspondingly deprecated it.

In August I attended a Haskell Hackathon in Cambridge, with three projects in mind: replacing the somewhat aged standard network library with something more carefully designed, working on a Haskell typechecker more lightweight than GHC's, and attempting to get the next-generation Hackage off the ground. The first two of these fell beside the wayside a little, and while I did submit a couple of useful patches to hackage-server, I made no serious progress on the things that needed doing, so I decided to set my sights a little lower and gain some experience before tackling it again.


I wrote my first wholly original package, notcpp, a Template Haskell utility library for helping programmers avoid the C preprocessor. I stopped maintaining pointfree (because I had inherited it broken and couldn't easily fix it) and applicative-quoters (which, though a decent package, was unused even by me).

I contributed a small patch to GHC.

I forgot to update my website, and then when I remembered I forgot what I did in 2012.