Syntax Highlighting on the Web

The state of Syntax highlighting on the web, why I think JavaScript highlighting libraries make more sense than server side solutions and how that relates to Markdown.

more ...



Nosetests, Generators and Descriptions

I’ve recently been playing around with the nose testing framework for Python. It’s pretty slick! With the various hooks for plugins, one can make it work pretty much however one wants. And what I especially like is support for generators. However, even with all this power, giving a meaningful name to each generated test is less than straightforward. Here are a few approaches that work.

more ...


Announcing Django-SpamBayes

I’ve just released Django-SpamBayes v0.1 which includes a few utility apps for Django that offer an easy to use interface to the SpamBayes statistical anti-spam filter allowing filtering and moderation (with training) of comments, contact forms and other publicly submitted data. Currently, two applications are available: DjangoBayes, which wraps the Django model and provides the SpamBayes API; and CommentBayes, which is an add-on to Django’s contrib.comments application and provides filtering and moderation of comments through signals.

more ...






Django Blog and Markdown

As I mentioned previously, I wanted to edit my posts in Markdown. I had played with Markdown both in Python and Django before, so it was a rather simple addition, but I wanted it to work without hiccups on different systems with varying needs. Therefore I can up with the following ‘markdown’ filter:

more ...

K2 with Django

Some time ago, Jay Skabber stated that his blog was powered by Django, and used K2 templates converted to Django’s template format. Of course, any one could see at a quick glance that he was using his own styles in place of the default K2 styles. In the spirit of the CSS Zen Garden, this is part of the beauty of K2. A sound html base is provided that any designer can build upon making it necessary to only provide a new style sheet and images to get a very difference looking site.

more ...