No more MySQL on my machine

I've said it before: I think MySQL is a toy, and I want as little to do with it as possible.

Unfortunately, since the KDE PIM suite depends on akonadi, which depends on a database, which was initially implemented against MySQL, not having MySQL installed on a Debian machine if you want to use the KDE PIM suite, for the longest time, wasn't even possible. Today it is, but it requires some manual steps:

sudo apt-get --purge install akonadi-backend-postgresql akonadi-backend-mysql-
akonadictl stop
rm -rf .config/akonadi
rm -rf .local/share/akonadi
cat > .config/akonadi/akonadiserverrc <<EOF
[%General]
Driver=QPSQL

[QPSQL]
Name=akonadi-wouter
Host=
Options=
StartServer=false
EOF
createdb akonadi-wouter

Change "akonadi-wouter" for a suitable database name.

And now it should work. Note that this requires you run PostgreSQL system-wide and create a system-wide database in that server. It should, in theory, be possible to have akonadi run its own private PostgreSQL instance, much like how the MySQL backend does things, but a) I couldn't get that to work, and b) I don't think having each user run their own database server instance is a good idea to start with, so honestly I didn't try very hard.

And there, pronto! I now no longer have toy databases on my laptop. Word.