Attacked and rebuilt
You may have noticed that all my sites went dark last week. This was in response to my discovery of a severe intrusion into my hosting account, as a result of which malicious Javascript was injected into every single page.
- Read more about Attacked and rebuilt
- Add new comment
- 104245 reads
Switching to Git
I migrated my SVN repository to Git yesterday and moved the XBBCode project to GitHub Drupal.org yesterday. The git migration should make it much easier to manage multiple branches for different Drupal core versions, and also make it much easier for others to contribute in case anyone is interested.
- Read more about Switching to Git
- 3 comments
- 10200 reads
XBBCode revisited in Python
In recent years I have switched from PHP to using Python for most of my programming. That's not because PHP is particularly bad, because having worked with Drupal for most of seven years now, I dismiss that frequent criticism as a mixture of outdated complaints, inexperience and personal taste. PHP doesn't suck, but Python is incredibly awesome. It has lambda expressions! Array slicing! List comprehensions! Lazily-evaluated iterators! In Python, once an algorithm is written down in pseudocode, its implementation is trivial.
Extensible BBCode for Drupal 7
I'm happy to announce that my extensible BBCode module XBBCode is now ported to Drupal 7. I last worked on (and wrote about) this module in April while writing a new parsing engine for it.
Paper-based computing
While traveling to a workshop with a friend and family this morning, I had the rare occasion to be not only awed by a piece of technology, but completely flabbergasted at its existence. This friend has a liking for cool gadgets, and what he showed me today had me first suspecting some sleight of hand, then shortly later positively drooling. The best part? It's a fraction of the price of a netbook.
- Read more about Paper-based computing
- 3661 reads
Server moved, PHP rebuilt
Yesterday, the entire Ermarian Network was migrated to a different server. After spending the past four years on millhouse, an AMD Opteron machine with two 2GHz cores and 2GB RAM, it is now hosted on carvin a brand new Intel Xeon with four 2.5GHz cores (hyperthreaded to eight virtual cores) and 16GB RAM. These impressive numbers are of course slightly misleading, since I'm one of a great number of users sharing the server.
Code Jam 2010
The first qualification round of the Google Code Jam just ended, and I managed to scrape through with two of the three problems solved in time. On the third, unfortunately, I failed to take into account the orders of magnitude of complexity, and my algorithm was not fast enough to solve the larger input case.
- Read more about Code Jam 2010
- 4805 reads
Hard drives and stupidity do not mix
At 0400 on Wednesday (yesterday), my home partition suddenly disappeared. I didn't have a clue what had happened, but the problem persisted on reboot.
Now, Enki has two hard drives - one contains /home, and one contains my backups. I was able to mount the backup drive manually, but the one containing /home appeared to be unresponsive.
So I took out what I assumed to be the defective drive. I then connected it to a different computer and was instantly smelling magic smoke.
Building a better Tag-Parser, part 2
As I concluded in the first part, one problem remains with the strict "inner-tag-first" evaluation of code (which roughly equates to a Left-Right-Root traversal of the code tree). Namely, some tags, like [nocode], require that further code inside them is not parsed.
Building a better Tag-Parser
The Problem
If you read the code of my Extensible BBCode module for [[Drupal]], you'll notice that my tag parsing algorithm is kind of complex. In two steps, the tags are first "paired" (inserting a matching ID into the opening and closing tag) and then "rendered", all by an evaluated regular expression that calls another function. The process certainly ensures that all tags are balanced - and it even allows some tags to be rendered before others are, regardless of nesting.
- Read more about Building a better Tag-Parser
- 7292 reads

Recent comments