Well, I’ve almost done it. (Warning: tech talk!)
Almost in the sense that the site isn’t what I’d like it to be yet, but the blog itself is back up and running. Transitioning from Blogger, which dropped its FTP support, to Movable Type, which I had wanted to do a couple of years back and just didn’t figure out at the time. So, here’s the deal, and maybe how to do it if you need to.
First off, installing Movable Type 5 couldn’t have been easier. I
downloaded it from their site, installed it into my webserver through
Cyberduck FTP, followed the very simple instructions, and it almost
worked. But the configuration file wouldn’t write. For some reason the
instructions didn’t tell me that I needed to <i>create the
database</I> before I could run MT. Luckily, my webserver host, Arvixe,
is pretty easy to use, and in my control panel I found the shortcut for
creating a database in MySQL. Then I went back to the MT configuration
wizard (it runs in a web browser, but is a file you’ve installed on
your site, and once I figured out that it needed my master account
username (not the username I created in MySQL), the configuration
wizard worked. Then it let me create an administrator account, and I
was on to the joy of the MT interface. That’s not sarcasm; after years
of putting up with Blogger’s clunkiness, slowness, recalcitrance, and
phenomenally slow publishing, MT is just a breath of fresh air.
I
then set up the blog site, not quite the way I wanted it. MT wouldn’t
let me put it in my site root, I had to go at least one level down to a
subdirectory called /blog. Thought that wouldn’t be a big deal. But
then when I named the blog, it took me down yet another level, to
/blog/mynonurbanlife – now this is getting a little tricky,
and not how I want my site organized.
Now, time to bring over the stuff from Blogger, all my brilliant witticisms and bon mots dating back to 2002. Should be easy, right? Yeah, right. This article at
eHow is an excellent set of step-by-step instructions for exporting
your Blogger files and then taking them up into MT. Unfortunately, the
export settings in Step 2 gave me files that walked me into a known
(and unfixed) bug in the MT importer. I tried and tried various fixes
on all those files, but running them through the importer always gave
the same result – it said all files were imported
successfully, but they were nowhere to be found. I tried changing
coding to UTF-8 and several other settings changes, but to no avail.
What worked in the end? Well, it wasn’t fun, but it worked.
First,
I went to my Blogger dashboard, chose the settings tab, and then
clicked on “Export Blog” (under Basic Blog Tools). That will drop an
XML file somewhere. Of course, I couldn’t find a simple way to import
an XML file into MT. Finally found out there’s a Google App for doing blog conversions,
that runs in Python (relax, it’s just another scripting language).
Python is installed in OS X, but I updated it just to be sure.
Downloaded the app, installed Python, tried to understand the
documentation, and then spent an hour or two in Terminal, hopelessly
issuing commands that did nothing. Well, they did issue a wide variety
of error messages, and eventually I was able to narrow them down and
figure out what the problem was. The Google download will include a
“blogger2movabletype.sh,” a shell script that runs the other scripts.
Drop it in the terminal window, add the filename you want to operate
on, and all should be well. I’m not hugely experienced in Terminal
commands, but I’ve been around since before DOS, so it’s not
unfamiliar, either. Eventually I was able to get a stable, consistent
error – it told me I had “no module named ISO8601.” (My
experience with DarwinPorts and all these others is that I’m always
missing something.) Couldn’t find it, couldn’t find it, couldn’t figure
out where to find an install for it, just about to give up, and then
figured out that I just needed to run a simple, but apparently obscure,
install. In the Terminal, the command was this:
$ sudo easy_install -U iso8601
Okay,
so I got my Python script to execute — drag the shell script to the
terminal window, drag the XML file to the terminal window, press
return. Running beautifully, but it wasn’t giving me an output file. In
the terminal window, I had a beautiful error-free run of the file,
showing my entire blog going back 8 years, but no file saved anywhere.
I had no idea why. It should have been outputting to a file somewhere.
Eventually I had a brainflash – I didn’t need a file. I could
just cut and paste from the terminal window into a UTF-8 encoded text
file. So I did. And I ended up with plain text entries that looked like
this:
AUTHOR: Carl
TITLE: Coffee and catholicism
BASENAME:
STATUS: Publish
ALLOW COMMENTS: 1
CONVERT BREAKS: 0
ALLOW PINGS: 1
PRIMARY CATEGORY:
DATE: 05/29/2008 03:59:00 PM
—–
BODY:
I
just made the afternoon pot of coffee, which is usually “afternoon” in
name only, as we basically wait after the first pot of the day just . .
.
Now, if you’re coming from Blogger, it’s
only been a couple of years that they have used true titles over there.
Those titles will come in as title entries in your new MT database just
fine. But if your entries don’t have titles, you want them. Otherwise
your database of entries will show lots of ellipses, and you won’t know
what you’ve got. You could probably write a script to do the painful
process, but I just did it by hand, deleting every H2-bracketed heading
from the old school, and pasting it into the TITLE: field, as above.
Then, I went to MT’s Tools menu, chose import, pointed it to the file
on my desktop, and everything went very quickly. If you can say that
about anything that took two days of work.
I’ll update this as I
go on trying to get my site back to the way I want it. Right now, other
than a bit of a glitch in organizing the site, I am loving Movable Type.
Well, it may have taken you two days, but thanks to your excellent writeup, it took me 10 minutes. Cheers.
Thanks, Scott — I was hoping it would be helpful to others!