After searching (and finding no existing solution), I created a small JavaScript-based commit-badge/banner which you can show of on your website to point at the latest (or a specific) commit in a Github-repo. This is what it looks like (if you see blank space here or something fubar please reload the page and after that complain ;):

(A live version with more than one repo can be seen here.)

So far this badge works with Firefox, Safari 3.x and Opera. I haven’t had the resources or motivation to make it work on IE though.

This has been my first foray into the world of JavaScript and DOM, and the first time I really wrote a CSS from scratch, so expect things to be buggy and the code to look slightly amateurish. The script uses JavaScript-libs, which I packed into one big file. jQuery is used to get the data from the Github API, Datejs for parsing the timestamp and an MD5-lib for requesting the gravatars.

If you want to use it on your website you should just download everything from Github and put it on your webspace. The README shows you how to embed it into your webpage (I made sure that the CSS-elements don’t clash with your existing stylesheets).

If you want to contribute to it you’re welcome to (the easiest way is forking the repo at Github), but please don’t try to make it into a monster-app which does much more than it was intended to do.

Thanks go out to DrNic for contributing and also for his Github-badges project for the good code-examples.

(By the way, Github asked for a JavaScript-version in this blog-post, so here it is. I hope they’re not mad at me for stealing the two tiny logos. ;)

Update: I notified defunkt of GitHub and what do you know, I got featured on their blog (entry here). Awesome. I hope I can put some further touches into the project in the next few days.