The Omni Group
These forums are now read-only. Please visit our new forums to participate in discussion. A new account will be required to post in the new forums. For more info on the switch, see this post. Thank you!

Go Back   The Omni Group Forums > OmniFocus > OmniFocus Extras
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
Applescripts: Better Templates, Complete Tasks From Mail.app Sender, and Batch-Defer Thread Tools Search this Thread Display Modes
Hello all,

I have been working on a few OmniFocus Applescripts and I figured I would share them here.

Templates.scpt looks for a "Templates" folder (or prompts you to select a folder where you store template projects), and then gives you a list of projects in that folder to create a new instance of. It then creates a copy of the project, sets the project's status to "Active", and moves it to a folder of your choosing. Variables are defined using a symbol of your choosing (default is "$"), and the script will replace any instances of those variables with replacements of your choosing (including variables in the project name and the tasks' names, notes, and contexts). Finally, you can define a relative date in the note of the template project (for example, "start: today + 3w at 2pm" or "due: 5d 14:30") and the script will automatically assign the calculated date to the due/ start date of that item.

Mail Complete.scpt is run from Mail.app. It detects the senders of selected messages and looks in your OmniFocus library for tasks with a "Waiting For" context that includes the name of that sender. It then offers to automatically complete any selection of the tasks it finds in a dialog without having to go to OmniFocus.

Later.scpt will defer all selected tasks by a user-defined amount of time. You can set either the start or due date, and the time to defer it by can be defined using any of the smart date syntax you usually have in OmniFocus (for example: "2d 5pm", "3w 14:00", "Jan 30 4am" all work).

The most recent version of all three are on the "Projects" page of my website, pxldot.com/projects. I would post them (or links to download them) here, but this is my first post so it's not letting me. Hope some of you find these useful! Let me know if you have any questions about them.

(Link added by moderator: pxldot.com/projects)

Last edited by Lizard; 2013-01-22 at 05:38 PM..
 
Welcome to the forums! Someone here just linked me to your scripts recently. I hope you don't mind me editing your post to include an actual link.
 
Welcome!

I just wanted to thank you for your scripts, I think that the template script is just amazing! I donīt know how to thank you enough for that.

May I raise a thought about that script?

Would it be possible to also activate the use of locations in the script?
Imagine for example that iīm going to attend to a conference in a few weeks. In the notes in the templateproject I added the due time for the conference, and itīs name as variables for the script to change - that way I have a nice template for tasks I have to do before the conference begin. But could I use the script, to activate the tasks I want to do after the conference have ended, when I reach a certain location (like my office for example).

(I hope that you understand, english is not my first language. Also I hope that I donīt offend you in any way asking this question).

Great work anyway
Kindest regards/G

Last edited by gazt; 2013-01-23 at 01:56 AM.. Reason: spelling
 
I also wonder if the possibility to subtract from any variable is written into the script (eg. time from start/due date).

I tried this morning to set $date as one variable in the projects notes, and either add days in the task note (ex: start: $date + 2d, Due: $date 09:00) or subtract days (ex: start: $date - 2w 09:00). I only success when Iīm adding days to the $date variable, and get no result with the subtraction. If I use the conference example above I could add the due date from the $date variable in some tasks, while other ones (like booking room and travels) I would like to automate so the task start for example 8w before the conference starts (eg. the $date).

Anyone that have any thoughts about that?
All the best
 
Quote:
Originally Posted by gazt View Post
I also wonder if the possibility to subtract from any variable is written into the script (eg. time from start/due date).

I tried this morning to set $date as one variable in the projects notes, and either add days in the task note (ex: start: $date + 2d, Due: $date 09:00) or subtract days (ex: start: $date - 2w 09:00). I only success when Iīm adding days to the $date variable, and get no result with the subtraction. If I use the conference example above I could add the due date from the $date variable in some tasks, while other ones (like booking room and travels) I would like to automate so the task start for example 8w before the conference starts (eg. the $date).

Anyone that have any thoughts about that?
All the best
gazt, thanks for the idea —*I have now added a special date variable that can be used in the way you are describing. You can grab the most recent version of the script with this built in from the link in the original post.
 
You are amazing! thank you

I moved the first template script away from the script-folder and renamed this last version, so I knew that I tried the right script.

Unfortunately when I tested it, there was no difference now from the first version of the script. When I tried to subtract, using $date in the notes as well in title, or the ask-command (tried with both $ask and just ask) the script worked just as before. I donīt know if this have something to do with that I still uses OS x 10.6.8? or if I misunderstood your instructions.

Like the last version I also canīt use w (week) or y (year) as datevariables - only d (days). Anyone more that faces the same problem?

Keep up the good work, still an awesome script. Iīm just sorry that I canīt add more then feedback and ideas.

Last edited by gazt; 2013-01-31 at 09:59 PM..
 
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Defer (or 'snooze') tasks/projects dbyler OmniFocus Extras 37 2011-08-29 05:26 PM
how to clip a mail from mail.app to OF such that OF action title includes sender name msim OmniFocus Extras 7 2010-10-01 03:24 PM
Snooze (not "defer") tasks/projects dbyler OmniFocus Extras 0 2009-02-26 06:59 PM
Tasks complete/ part complete move to start of project? Omni User OmniPlan General 1 2008-06-16 11:08 AM
More Entourage to OmniFocus applescripts: this time it's tasks and notes spnyc OmniFocus 1 for Mac 0 2007-06-24 09:10 AM


All times are GMT -8. The time now is 08:13 AM.


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