Python mysql and unicode

The top google result for the search terms mysql, python, and unicode is a blog post that recommends using the init_command option to the construct a MySQLdb connection to run the SQL ‘SET NAMES utf8’. A better way is to set the charset option to ‘utf8’. This way MySQLdb realizes the connection is using utf8 and encodes things properly. For more explanation see MySQLDB’s user guide.

Enabling history in shell scripts

If you’ve ever found yourself trying to log the commands ran by your bash scripts (and cursed your failures to quote and escape them properly), then try using bash’s built in history functionality instead. Below is in example of how to turn it on within a script.

Rss mod for phpbb2

If anyone is using the following mod to a phpbb installation,

Dokuwiki httpclient fix

For a while now, I had an annoying error every time I created a new page in DokuWiki.