The Changelog

Open Source moves fast. Keep up.

Mailman: If Sinatra worked at the post office

As part of the Ruby Summer of Code, Jonathan Rudenberg has released Mailman. Mailman aims to provide the classy Sinatra declarative style for handling incoming mail:

Mailman is a Ruby gem so it’s easy to install:

sudo gem install mailman

Then you’re ready to start handling some mail:

require 'mailman'

Mailman.config.maildir = '~/Maildir' do
  to '' do


  from('').subject(/RE: (.*)/) do
    params[:user] #=> 'chunkybacon'
    # it is an indifferent hash, so you can use strings and symbols
    # interchangeably as keys
    params['captures'][0] #=> 'A very important message about pigs'

Simple and classy.

The comments on Jonathan’s original blog post suggested he change the name to something more Googleable. Jonathan, if you’re open to suggestions, might we suggest KarlMalone?

[Source on GitHub]

Have comments? Send a tweet to @TheChangelog on Twitter.

Subscribe to The Changelog Weekly – our weekly email covering everything that hits our open source radar.