Omnifocus delegation

Hello! for the most up to date version of this code please visit https://github.com/jeredb/Delegated

After seeing Sven Fechner’s tweet about Sparrow’s scriptability and OmniFocus delegation and then looking over Don Southard’s code, I figured it would be easy enough to modify the script for use in Apple’s default Mail.app. As soon as I had finished up my modifications, I saw Benjamin Brooks post his modification of the code that did the exact same thing my code did. The exact same thing. I messaged him, he messaged me back and then I saw the modification he posted

… embeds an OmniFocus link to the script that will allow another OmniFocus user to add it with just a click … very cool!

For some reason I remember reading somewhere that the goals for OmniFocus versions (Ken Case, maybe. OmniFocus forums, maybe.) went something like 1.0 was for single users, 1.5 was syncing across devices and that 2.0 was for teams. I am super hyped for OmniFocus 2.0, but in the mean time, I have baked up another script.

My script relies on rides on the backs of several other Applescripts.

See https://github.com/jeredb/Delegated for the Delegate Applescript

The script (I am sure this thing is horribly broken and awfully coded, but it does appear to work for me. Your mileage may vary, no warranties or guarantees. If this script breaks your stuff, please don’t hold me responsible, I have kids to feed and can’t afford being sued. CTRL-Z is your friend. Call your mother. Rights given up, no copyright attached. If I swiped your code, I mean no harm, see my note re: kids.) uses the above scripts and the is a modification of the Benjamin Brooks scripts. If the variables in the script are set correctly, the script will:

  1. Encode the OmniFocus task (for use in the email message)
  2. Run the Defer script (if indicated)
  3. Run the Delegate script (if indicated)
  4. Gin up the OmniFocus information for the email
  5. Set the message subject to user set text, plus task name
  6. Create the “Add to OmniFocus” URL (if indicated)
  7. Create the “Open in OmniFocus” URL (if indicated)
  8. Create the new email message with the OmniFocus information

Here is my thought process:

  • I agree with Ben that Contexts are individually defined.
  • As much as I want people to get back to me immediately, I don’t want them to expect me to sit on email, so I don’t expect them to. In most cases I can give them a couple of days to get back to me.
  • I like that the Delegate script automatically changes the context and prepends what ever I want to the task that is being delegated. My options are set to prepend “Delegated:” and change the context to “Waiting For”
  • I delegate tasks to my wife (a fellow OmniFocus user), so I want her to be able to add them quickly to her system.
  • I want to easy get back to the task when i do get a response, so I have the “Open In OmniFocus” link. This streamlines my task clean up when I do finally get a response. Please give it a whirl. Hit me on the Twitter (@jeredb) if it works (or not).

Hello! for the most up to date version of this code please visit https://github.com/jeredb/Delegated

Updated 4/3/2015: Removed code to encourage the use of latest version on Github