Apple Mail: Keyboard shortcut to move to folder?

I spent some time looking into Alfred Workflows and created this one. Hope someone else can benefit or improve on it!

alfred-mail-sorter

Moves currently selected message in Mail.app to a folder selected via Alfred interface.

Usage

With a selected message in Mail:

  1. Press ⌃M (default shortcut) or invoke Alfred and type sort
  2. Type the name of the folder (or part of it) until you see the desired folder selected
  3. Hit return/enter

How does it work

  1. Uses AppleScript to enumerate folder names for the selected account and feed a Script Filter on the Alfred Workflow;
  2. Selecting the desired folder will feed the next action with the name of such folder;
  3. A seccond AppleScript will use the name of the folder to select the corresponding “Move to…” item in menubar.