Error in Things Todo Script

In my previous post I had in small error in the script that created the todos in Things from a mail message. Here is the updated script:


tell application "Mail"
set cr to ASCII character 13 -->You can probably use the Unicode Equivalent but I didn't know it and this worked right away.
set LF to ASCII character 10 --> Same as here
set carriage_return to (cr & LF as Unicode text)
set theSelectedMessages to selection
set the selected_message to item 1 of the theSelectedMessages
set message_id to the message id of the selected_message
set message_url to "message:%3C" & message_id & "%3E"
set TheSubject to the subject of the selected_message
set theBody to "[url=" & message_url & "]From: " & the sender of the selected_message & " - Subject: " & TheSubject & "[/url]"
tell application "Things"
show quick entry panel with properties {name:TheSubject, notes:theBody}
end tell
set currentMailbox to the mailbox of the selected_message
set currentAccount to the account of the currentMailbox
set filedMailbox to "All Mail"
move selected_message to mailbox filedMailbox of currentAccount
end tell

Things Mail Script

ThingsRecently I have been trying to be more focused on the stuff that I need to get done. Just like everyone, I have email, phone calls and such that lead to things that I have to get done. I seemed to be doing ok with most of them, but emails were getting lost in the sea of stuff that I received every day. I read this post from Michael Hyatt and thought that I would give inbox zero a try.

So to get to inbox zero I had to employ some tools to help make this happen. The rule is that if you can deal with the email within two minutes, just get it done. If not then it becomes a task. OS X doesn’t really have any good tools to handle tasks and nothing at all that would sync with the iPhone. I don’t want to go into the details of of my choice, but I ended up with Things on the desktop and iPhone.

I’m a distracted person and for me to keep up with a system it has to be easy. I quickly get frustrated by software not being integrated so I go back to my same old ways. If this was going to be successful I would need to implement some apple scripts. Two keystrokes is what I needed. If I had handled the email I need a command to move the message to my “All Mail” folder and if not another command to create the task. Things has extensive Apple scripting support so I was on my way. I found some sample code in the Things Wiki and modified it to suit my needs. I will put the code for the scripts at the bottom of this post.

Come to find out the scripting was the easiest part of this project. It was harder to find a way to run the script from a keystroke. During my research I keep coming up with MailActOn which I downloaded and it did the trick, but I just couldn’t bring myself to purchase it. The only feature I needed was the keystroke mapping and thought there had to be an open source solution to my problem. After digging deeper into Google, I found out that the swiss army knife of Mac software, Quicksilver, could solve my problem. I’m not going into the detail of how to set it up in this post, but with a little research I was up and running.

I have been working with this solution for about a month and so far I have really liked it. Of course the scripts only work on my laptop and not on the iPhone, but with copy and paste in iPhone 3.0 I have survived. I hope that the Things people add a way to create a to do from a mail message on the iPhone.

Move Message To “All Mail” Folder Script:
At some point I’m going to update this script to move multiple selected messages, but right now it only moves one.

tell application "Mail"
set theSelectedMessages to selection
set the selected_message to item 1 of the theSelectedMessages
set currentMailbox to the mailbox of the selected_message
set currentAccount to the account of the currentMailbox
set filedMailbox to "All Mail"
move selected_message to mailbox filedMailbox of currentAccount
end tell

Create A To Do And Move The Message To “All Mail” Folder Script:
tell application "Mail"
set cr to ASCII character 13 -->You can probably use the Unicode Equivalent but I didn't know it and this worked right away.
set LF to ASCII character 10 --> Same as here
set carriage_return to (cr & LF as Unicode text)
set theSelectedMessages to selection
set the selected_message to item 1 of the theSelectedMessages
set message_id to the message id of the selected_message
set message_url to "message:%3C" & message_id & "%3E"
set TheSubject to the subject of the selected_message
set theBody to "[url=" & message_url & "]From: " & the sender of the selected_message & " - Subject: " & TheSubject & "[/url]"
tell application "Things"
show quick entry panel with properties {name:TheSubject, notes:theBody}
end tell
set currentMailbox to the mailbox of the selected_message
set currentAccount to the account of the currentMailbox
set filedMailbox to "All Mail"
move selected_message to mailbox filedMailbox of currentAccount
end tell

* Updated after an error was found

Unitaskers

Snow ShovelKind of sounds like a word that I made up, but it is not. Do you watch Food Network at all? Now come on men you don’t have to surrender your “man” card if you do. I love the show Good Eats and Alton Brown uses the term unitaskers all of the time. He doesn’t think a kitchen tool should only have one purpose. This got me thinking about my production environment and how many unitaskers we have.

I have attached a picture of a snow shovel or is it just a snow shovel? When we moved to NC it would snow on occasion, but I never wanted to pay for a snow shovel for the one to two times a year it would snow until I saw a neighbor use it as a dust pan. Might be the best dust pan I have ever used. Now it has value beyond the single task, I can own it. Of course I live in Southeast TX now and it has become a unitasker again, for now.

At churches we have lots of unitaskers, could be buildings, tech gear, volunteer positions. Sure there are times that you have to have unitaskers, but with some thought or changes could they be used for more? Let me share some examples from my world.

Do you have any wireless systems with only hand helds? Seems like it makes sense that you would have a handheld mic dedicated for solos or the worship pastor. What happens when VBS hits and all you need is headsets or lapels? It costs a little more to add the body pack, but think of the flexibility it adds. We have used them as guitar packs, drama mics, countryman on a violinist for a specials. I think that it is crazy to get a wireless with out both. Multiple times a year we use packs on channels we thought would be dedicated to handheld use.

We have yet to add a dedicated recording console in our worship environment, but I would make sure that I added a vocal booth or maybe even a larger room for doing voice overs/over dub/general recording as well and connect it to the recording console. Why should that be dedicated to doing a service mix only. The same applies to a dedicated video studio how could the equipment in your worship environment be leverage for the creative video work you do. This could be as simple as keeping a few backdrops in the worship center for shooting green screen or other types of shots. You already have the cameras, lighting systems and recording equipment. Would it be the most optimal? Maybe not, but it would be a good use of the equipment that that sits idle other than service times.

We are adding a stage camera next budget year and the camera we have budgeted for is not a studio only camera. I wanted something that could be used standalone for remote shoots or creative video projects. Adding a stage camera will also add a volunteer position that I think we can cover by the training the stage manager that has no responsibility during the worship section of the service. I don’t know about you, but volunteers can be harder to get sometimes than the money for new equipment.

I have two MacPro CG systems sitting in the worship center that are quad core Intels with a Declink Extreme capture cards for ProPresenter with Alpha channel. Great setup, but is that not also a video editing system? Why not have someone do video editing on them during the week? In our case it is pretty expensive to have someone work in the worship center due to a/c and lighting costs, but if you have a video booth that is out of the main room why not leverage this equipment for video editors. At the very least, I plan on setting them up as render nodes when the room is cool enough in the winter.

I could go on and on with examples, but you get the idea. We are spending money given to us by our Lord, it is not our money. We can’t totally eliminate unitaskers from our environments, but especially in financial times like we are in now we need to spend our money and use our resources wisely. Down with unitaskers!!!!

SaveSave