Email Your Middleman Blog

Hello everyone!

I just released an email-to-blog parser specifically designed for statically Middleman (and, later, Jekyll).

Yes it sounds crazy, since we’re talking about static sites here, but I really love Middleman and I really like being able to email my blog photos while on the road.

It’s called Mail2FrontMatter. It has a very simple configuration and ships with an executable which polls a specified email address (via Mailman) for posts.

It spits out YAML FrontMatter and a post body in ERB (other templating options eventually, namely Markdown) to your ./source/blog directory

I am using it in combination with guard-middleman to live-ish update when I email my blog’s address (a gmail account).

Additionally, it is very easy to make plugins (processors) to manipulate the email before it gets posted.

I’ve released two such plugins today, one extracts tags from your subject line.

The other requires automatic-clowncar (responsive image generate for Middleman) and simply places your incoming images into the directory clowncar expects it to be in and replaces image tags with the appropriate ERB. That’s here

I’ve got more work to do, documentation and importantly sanitization of incoming emails, but I’d really love some feedback if you have any to offer.

Just posted to my blog here:

1 Like

This is really cool! I always thought about something like this, but I was too lazy (and probably not experienced enough in Middleman) to start working on it. I’ll give it a try!