Archive for the ‘Software’ Category

Compiling ejabberd 2.0 on Debian (Etch)

Saturday, July 12th, 2008

Etch has ejabberd 1.1 packaged but if you’re like me you’ll want to play with the new features in 2.0, in which case you’ll need to build from source. Etch’s packaged version of Erlang is apparently not up to date enough to support it (it compiles fine, but I couldn’t get TLS to work) so you’ll need to build a newer version of that as well. Luckly it’s all easy. This following is all from your home directory on a fresh install of Debian:

(more…)

Apache Commit Visualisation - code_swarm

Tuesday, July 8th, 2008

The video below is a brilliant piece of work by Michael Ogawa - a visualisation of the commit history of the Apache httpd. It was built using Processing and the source is here, theoretically (i.e. I haven’t tried) allowing you to produce a similar visualisation for any project.


code_swarm - Apache from Michael Ogawa on Vimeo.

I suggest viewing it in full-screen mode.

There are several other examples available at the project page. Impressive though it is, I can’t help thinking that an interactive version of this would elevate the concept from eye-candy to something extremely useful.

Update: Ok, an interactive version like this perhaps. Wow!

Trains and Grapes

Tuesday, July 1st, 2008

According to Google nobody has ever seen fit to utter the phrase “trains and grapes” on the internet before, so it’s lucky I’m here to put that right. In my defence, the real purpose is a bit of testing of video encoding and embedding. Firstly, Saturday morning fun with Duplo trains:

Get the Flash Player to see this player.

Secondly, a more serious use (it’s all relative) of the same setup, namely providing a guided tour of the grapevine:

Get the Flash Player to see this player.

The camera shoots the video in MPEG format, so I used Riva FLV Encoder to convert them to the more web-friendly FLV format, and also to reduce the resolution and bitrate a bit. This Wordpress plugin made it easy to embed the videos into the post. Although it was a bit more effort, I much prefer this approach to relying on an external service to encode and host the video as I did here.

Java is now malware?

Friday, May 16th, 2008

JRE update wants to install unwanted junk, by default

Yep, as of this morning, I consider Java as malware. Having put up with the JRE updater being used as an advertising platform for some time now, the final nail in the coffin came this morning with JRE 6 Update 5. This attempts to install a stinking “Yahoo! Toolbar for Firefox/Mozilla”, and while there’s a checkbox to turn it off, it’s enabled by default.

As far as I’m concerned, this is totally unacceptable and Java and Sun just went down an awful long way in my estimation.

How to incur technical debt

Saturday, May 10th, 2008

I guess you’re worried that when your project has no bugs, or when maintenance becomes too easy, someone is going to start wondering what they’re paying you for. What you need is technical debt. Here my top 10 ways to sneak some in your codebase. As well as plenty of future bugs, this will ensure that any maintenance or expansion tasks take as long as possible.

  1. Create lots of overloaded versions of the same function. Only use one.
  2. Copy and paste code. For bonus points, change the pasted versions slightly.
  3. Leave chunks of commented out code (”Green Code”) lying around.
  4. Don’t use existing core logic. Reimplement it within the user interface using your own strange methodology. Make sure it behaves subtly differently. No need to check that, it will.
  5. Check several unrelated changes in at once. Only mention one in the check-in comment.
  6. Never use 5 lines of code where 50 will do.
  7. Never use 50 lines of code where several classes that almost resemble a GOF pattern you misunderstood will do.
  8. Invent your own naming conventions.
  9. Never fix a bug - hide it. For example, deal with null reference problems by simply sticking an if-not-null around the offending code. This saves you having to look for the real source of the problem, and also ensures the bug will come round again in a more subtle and interesting manner.
  10. Leaving out documentation is too obvious. Much better to document it, but make sure the code doesn’t do what the documentation claims.

It Crashes

Wednesday, April 16th, 2008

Any software developer will be able to tell tales of bug reports that don’t give enough information to reproduce the problem. My all-time favourite said just this: “When you take off from the aircraft carrier in the F4 Phantom, it crashes.” Not an unusual scenario - a complex flight-sim written entirely in 80×86 assembler tends to either work perfectly, or crash.

(more…)

Inquiry

Saturday, April 12th, 2008

Why are hardware manufacturers so incompetent when it comes to software? The wonderful message below was followed by three more equally insane error dialogs.

Inquiry

Super Mario Bros in Javascript

Thursday, April 10th, 2008

This excellent piece of work raised a smile - the first level of Super Mario Bros implemented very neatly in Javascript. It’s 35K for the whole lot, compressed down to 14K. For comparison, the small screenshot in the article is 24K!

Mobile Web “Acceleration”

Wednesday, April 9th, 2008

How do you make web browsing faster on a GPRS connection? The answer seems to be by injecting huge blocks of javascript into pages, turning 6KB of well-formed XHTML into 23KB of junk that refuses to render because it’s invalid.

(more…)

Proper Snow

Sunday, March 23rd, 2008

It turns out I was wrong about the annual day of snow, as we had some proper snow today complete with snowballs and a snowman. Only the chickens failed to get into the spirit of things, refusing to come out of their house.

Snowed In

If the image looks odd, it’s a result of me inexpertly playing with multiple exposures to create an HDR image using qtpfsgui.