Converting Wordpress to Mephisto
I’ve been contemplating converting my site to Mephisto, mostly because it’s 100x more pleasurable to write code for Ruby on Rails than it is for PHP, but also because I get bored easily, and it’s something to do. I found a guide to doing this, which was very useful.
Except, for some reason, a lot of my comments have missing bodies, URLs or author names, and for some reason, this just doesn’t work with Mephisto correctly. Now, I don’t know how they got that way, but in the interest of expediency, and so that I’d have it to work on on the plane trip today, I modified the conversion program, and made it fill things in. The fun part? I was pulling it from a remote MySQL database (over an SSH tunnel for the session) to my local PostgreSQL database.
You can find the diff here. This gets applied to .../vendor/plugins/mephisto_converts/lib/converters/wordpress.rb, and poof, it’ll recover from the craziness. It’s a hack, but it works.
This entry was posted at 1:23 pm on 24 October 2006 and is filed under Ruby. You can follow any responses to this entry through the post-specific RSS 2.0 feed.
Thanks Rick. Another thing I found was that Sections and Users don’t seem to port correctly. Since I don’t have much network bandwidth where I am, I’m not working on that right now, but it’s my intention to take a look when I get home and iron it out. Also, likely, offer an option to convert Sections to Tags, as that’s a common use in WP.
Responses are currently closed, but you can trackback from your own site.
Thanks for this. I’ll make sure it’s in the final 0.7 release of Mephisto.