The Omni Group Forums

The Omni Group Forums (http://forums.omnigroup.com/index.php)
-   OmniFocus 1 for Mac (http://forums.omnigroup.com/forumdisplay.php?f=38)
-   -   OmniFocus-Mail Links (http://forums.omnigroup.com/showthread.php?t=3809)

curt.clifton 2007-06-10 07:32 PM

OmniFocus-Mail Links
 
Inspired by zooids post in another thread. I've created a pair of scripts that allow round-trip linking between OmniFocus and Mail.

The pair of scripts here allow you:
• to create OmniFocus actions from messages in Apple Mail
• jump from linked OmniFocus actions back to the Mail message.

Download: [URL="http://www.rose-hulman.edu/~clifton/software.html"]the most recent version is available here[/URL]

[B]Installation[/B]
1. Copy the Add OmniFocus Action script into the folder:

~/Library/Scripts/Applications/Mail

creating the folder(s) if necessary.

2. Copy the Open Linked Mail Message script into the folder:

~/Library/Scripts/Applications/OmniFocus

creating the folder(s) if necessary.

3. Add the Scripts menu to your menu bar if you haven't already by opening the AppleScript Utility, located in Applications/AppleScript/, and selecting the “Show Script Menu in menu bar” checkbox. The menu should appear on the right side of the menu bar.

[B]Running[/B]
When running Mail, the Add OmniFocus Action item should appear in the scripts menu. Select a message in Mail, then run the script. You should find a new action in your OmniFocus Inbox awaiting a context and project designation.

When running OmniFocus, the Open Linked Mail Message item should appear in the scripts menu. Select a linked action in OmniFocus, then run the script. The mail message should open.

[B]Disclaimer[/B]
I haven't tested the scripts with IMAP accounts. OmniFocus is still in alpha testing, so the scripts may break at any time. I suspect that I'll continue to use and maintain them until the Omni Group provides built-in support, so I'm likely to maintain the scripts for awhile at least.

johnrover 2007-06-11 05:45 AM

Awesome. This is great. This makes OF twice as useful to me.

One request – does anyone know how to make the script select the message in the main mail window (and have it open in the preview pane) instead of opening it in a new window? It's really helpful to see the message in the context of it's thread / folder / mailtags, etc instead of just opening it.

curt.clifton 2007-06-11 06:15 AM

[QUOTE=johnrover]Awesome. This is great. This makes OF twice as useful to me.[/QUOTE]

I'm glad you like it. It was like pulling teeth to get Mail to behave!

[QUOTE=johnrover]One request – does anyone know how to make the script select the message in the main mail window (and have it open in the preview pane) instead of opening it in a new window? It's really helpful to see the message in the context of it's thread / folder / mailtags, etc instead of just opening it.[/QUOTE]

That's a good idea. Let me make sure I understand what you're looking for. You would like the front message viewer window in Mail to switch to the mailbox of the linked message with the linked message selected. Is that right?

Should the current behavior of opening a new window also be retained as an option? I can imagine some people not wanting the script to change what their message viewer is already displaying.

BwanaZulia 2007-06-11 06:30 AM

Haven't tried it but like the jail bird says... "That is hot!"

BZ

johnrover 2007-06-11 02:23 PM

[QUOTE=curt.clifton]
That's a good idea. Let me make sure I understand what you're looking for. You would like the front message viewer window in Mail to switch to the mailbox of the linked message with the linked message selected. Is that right?
[/QUOTE]

Yes!

[QUOTE=curt.clifton]
Should the current behavior of opening a new window also be retained as an option? I can imagine some people not wanting the script to change what their message viewer is already displaying.[/QUOTE]
[/QUOTE]

To be honest, I don't care. I would never use it that way. If I'm linking to something from OF, chances are I'm not already reading a message in mail. And in the few cases where I [I]do[/I] want to keep the message I'm reading open, I would open [I]that one[/I] first, because I'm already trained to work that way while working exclusively in mail.

The I thinking linking OF to the message in context, highlighting it (thus causing it do display in the preview pane) would be the most "seemless" workflow option. It would make OF feel more like an extension of mail, or vice versa.

Thanks again!

pjb 2007-06-11 03:12 PM

OT: Leopard Mail will have some interesting ways to connect to OF: Notes and autorecognition of dates (connecting to iCal) and addresses (connecting to Address Book) could be tapped for some subtle integration.

On Topic: I'd expect to move from OF to Mail with the message displayed in the main (read only) Mail window but could see a modifier key causing it to open in it's own window.

curt.clifton 2007-06-11 05:12 PM

New version
 
Here's a new version of the OmniFocus-Mail Links scripts. This one displays the linked message in the front message viewer of Mail.

Download: [URL=http://www.rose-hulman.edu/~clifton/software.html]the most recent version is available here[/URL]

(You can change one line in the appropriate script to use the old "open in new window" behavior. The zip file includes instructions for doing this.)

zooids 2007-06-11 06:46 PM

Nice job! Thanks for updating the scripts.

curt.clifton 2007-06-11 07:04 PM

[QUOTE=zooids]Nice job! Thanks for updating the scripts.[/QUOTE]

Thanks for the inspiration!

I probably should have just sprung for MailTags, and I still might, but it was fun to figure out how to make the scripts work with the stock version of Mail.

Richard Flynn 2007-06-12 03:40 AM

Nice work, good integration. Only problem—for me—is that the ID your script generates for messages in Mail only holds true while they are in the same mailbox (folder) within Mail. Move a message, and the link from OmniFocus no longer works. The Message IDs generated by zooids' original script, however, are unique to the message, and don't get broken when you move messages between mailboxes. I do really like being able to open linked messages within the preview pane of the main Mail window, but I think it's more important that the links continue to work, regardless of where you move the message to!

Plus, the latest builds seem to recognize the IDs generated by zooids' scripts as URLs, so you can now right-click on the links in the note attached to an Action in OmniFocus, and choose 'Open URL' to open the original message very easily in Mail.

Hope that makes sense…


All times are GMT -8. The time now is 03:55 PM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.