There was something I was supposed to be doing, and then there was the ugly reality that after I moved everything back over to WordPress, some of the images were lolling out of the margins of the primary column and a bunch of posts were categorized as “Uncategorized.”

At first I was content to just plod along with a canned BBEdit search/replace. Then it was tedious to click on the search box. Then it was irritating that there was something wrong with the way MarsEdit and BBEdit were talking.

The really lovely part of it all, though, when I got completely snagged on trying to turn what BBEdit calls “grep search” into AppleScript, was remembering that BBEdit is a really, really well behaved AppleScript citizen. I just had to click the record button in Script Editor, perform the actions I wanted to script, then click the stop button, and there was an AppleScript I only had to tweak a little. Then I saved it in BBEdit’s Scripts folder, gave it a keyboard shortcut, and all is well.