Archiving mail on IMAP server

Version 1.4 of MailArchiveByDate now supports archiving to IMAP

It works exactly as expected for me, but some users have reported
problems with the script not creating new mailboxes. If the mailbox
exists, the messages are moved. I have not been able to reproduce the
problem myself using dovecot on Fedora Core 4 or Scalix (which is
supposed to look like an Exchange server).

How NOT to Backup a Blogger Blog

Over at the Google Operating System blog, they offer a way to
“backup” your blog
. It is mostly a manual hack to load the entire blog
into one page in a web browser, then save the resulting HTML, though a
similar technique is offered for saving the contents of your XML feed.

There are a few problems with this technique:

  1. It depends on knowing how many posts are in the blog, up front.
  2. The steps and tools given are manual.
  3. Comments are handled separately.

A backup needs to be automated. If I have to remember to do something
by hand, it isn’t going to be done on a regular basis. I want to add to
my blog without worrying about how many posts there are and tweaking
some backup procedure that depends on knowing all about the content of
the blog up front. I want comments saved automatically along with each
post, not in one big lump. And if I need to import the data into a
database, I want the backup format to support parsing the data easily.

What to do?

Enter BlogBackup, the unimaginatively named, fully automatic,
backup software for your blog. Just point the command line tool at your
blog feed and a directory where the backup output should go. It will
automatically perform a full backup, including:

  1. Every blog post is saved to a separate file in an easily parsable
    format, including all of the meta-data provided by the feed
    (categories, tags, publish dates, author, etc.).
  2. Comments are saved in separate directories, organized around the post
    with which they are associated. Comments also include all of their
  3. The content of blog posts and comments are copied to a separate text
    file for easy indexing by desktop search tools such as Spotlight.

Since the tool is a command line program, it is easy to automate with
cron or a similar scheduling tool. Since it is fully automatic and reads
the feed itself, you do not need to reconfigure it as your blog grows.
And the data is stored in a format which makes it easy to parse to load
into another database of some sort.

So, go forth and automate.

Hawk Wings and Mail Archiving

I’m a little behind on my reading, so I just noticed that Tim over at
Hawk Wings is linking to MailArchiveByDate. I guess that
explains the email I’ve received in the past few days asking for help.

Tim comments that my update notes for the 1.2 release don’t convey
much meaning. I looked, and sure enough, they aren’t end-user-ready
release notes. I’ll try again. The original version of the script asked
Mail for the current selection. That meant, if you triggered the action,
then changed the selection by clicking on the next message, the wrong
message might be archived. The new version uses the selection
information passed to the script as an argument, so it is more reliable.

That’s still not very interesting, unless you are writing your own
AppleScripts. Suffice to say, if you are planning to giving it a try,
download the most recent version posted.

Better blogger backups

I have enhanced the blog backup script I wrote a while back to
automatically find and include comments feeds, so comments are now
archived along with the original feed data. The means for recognizing
“comments” feeds may make the script work only with, though,
since it depends on having “comments” in the URL. This does what I need
now, though.

Adium 1.0

My ChatMonitor script does not work with Adium 1.0. It looks like
the “chat” object no longer contains “content” objects. I haven’t yet
figured out how to get the content from a chat window. Oh, well. I guess
it’s time to order those OS X programming books!

testing regular expressions

I discovered Christof Hoeke’s retest program today. This is a very
slick use of Python’s standard library HTTP server module to package an
AJAX app for interactively testing out regular expressions. I used to
have a Tkinter app that did something similar, but Christof’s is much
lighter weight.

Now I need to figure out how to package it to run as an app when I
double click on it in the Finder, instead of opening the .py file in an
editor. monitoring feeds

On the plane back from Phoenix this week, I implemented some changes
to the way republishes feeds for the sites a user
subscribes to. The user page used to link directly to the original feed
so it would be easy to copy it to a regular RSS reader to keep up to
date on new shows. That link has been replaced with a “monitor” feed
which uses the original description and title for each item, but
replaces the link with a new URL that causes the show to be added to
your CastSampler queue. The user page still links to the original home
page for the feed, so I think I am doing enough as far as attribution
and advertisement. Any author information included in the original feed
is also passed through to the monitor feed. The OPML file generated for
a user’s feeds links to these “monitor” feeds instead of the original
source, too.

The goal of these changes is to make it easy to use a feed-reader such
as Bloglines or Google Reader to monitor podcasts from CastSampler. To
add an episode to your queue, just click the link in the monitor feed to
be directed to the appropriate page.

By the way, how cool is it to be able to develop a web app on my
Powerbook while I’m on a plane? What an age to be alive.

Adium ChatMonitor

We recently set up our own Jabber server at work. For a short time we
had been using an IRC server, but decided for a variety of
non-technical reasons to switch to Jabber. The benefit is now I only
have to run one chat client (Adium). The downside, is I miss the
feature of Colloquy which had a special notification event for when
I was mentioned by name.

I searched for a while, but didn’t find any way to add such a
notification to Adium. I finally hacked something together using an
AppleScript triggered for every incoming message. I’m sure there must
be a better way to achieve the same results, but this
works. Eventually I should learn more about how to develop true OS X
apps using Objective C, and then I can create a real plugin to do the
same thing.

Nothing new under the Sun

Or should I say IBM?

It turns out IBM Alphaworks already has a data visualization
project called Many Eyes that can render network diagrams as I
described in my earlier post. The demos look impressive.

Their UI for adding data requires you to upload from a separate
source, which makes the social aspect of my idea more difficult to
implement. Perhaps Many Eyes can be used as the visualization front-end
for a site that collects the data. Any data uploaded to Many Eyes
becomes publicly visible, but that’s not an issue since the original
site would have similar rules.

The network visualization from Many Eyes is more limited than what I
would want to see in a full featured tool, though. It could be very
useful to be able to see the types of relationships (using different
colors for edges, etc.). They also point out that since the rendering is
done in the browser, it may not be well suited for large data sets or
“for networks in which a lot of nodes have a large number of neighbors”.

Originally spotted on Boing Boing.