Have a conversation once or have it over and over forever

When a team is collaborating to create software, there are inevitably issues that come up in “big picture” areas like architecture and process. There are two ways to deal with these:

  1. Take some time out from the daily grind and discuss the issue until consensus is reached and a decision is made (and hopefully documented!) for how to handle stuff going forward.
  2. Don’t take the time to think (“We don’t have the luxury of time for thinking!”) and continually have mini-discussions about it (sometimes with other people; sometimes internally within people’s minds) every time it comes up again forever and ever…

I know which one I prefer. How about you…?

There is no reason ever to have the same thought twice,
unless you like having that thought” – David Allen

An unnecessary AppleScript to convert an OmniFocus task into a project

I hacked this up and then discovered via a tweet from Ken Case of the OmniGroup that it’s completely unnecessary, because you can convert a task into a project in OmniFocus simply by using the outlining outdent shortcut of Command-[. I thought I’d post it anyway, in case anyone finds it to be a useful example of scripting OmniFocus (which I found somewhat hard to get started with) and also because I feel bad about wasting time on writing this thing and publishing it somewhere kind of sort of justifies the effort. 🙂

Using TextExpander to expand a sequence of OmniFocus tasks: A failed experiment

I recently got turned on to TextExpander by the Mac Power Users podcast.

One of my ideas was to use snippets in OmniFocus to create certain repetitive multi-action sequences. For example, when a project involves emailing someone and then waiting for a reply, it would be nice to type a short abbreviation and then enter a fill-in for the name of the person and then have TextExpander create two actions in OmniFocus; one called “Email ” with a context of “Online” followed by another called “Waiting for reply from ” with a context of “Waiting”. I theorized this should be doable because TextExpander lets you insert key presses like Tab and Enter into snippets.

Well, it didn’t work for me as expected. Strangely, it works with the first action; I get the title and context that I want. For the second action, however, I cannot get it to set the context. No matter how many tabs I insert into my snippet expansion, any text that I try to make it put in the context field of the second task seems to go in the title instead. Strange.

Here is the snippet:

If you get it to work or have any insights, please let me know…

Append to nvALT journal – Alfred.app extension for nvALT

I whipped up a quick little extension for Alfred that lets me very quickly jot down time-stamped text. The hope is that if I make it ridiculously easy to log what I’m doing and when, then maybe I can have better records of what I’m doing and it will be easier for me to switch back to task after interruptions. I can also look at where I’m spending my time.

I have this extension mapped to the keyword “nj” (for “nvALT Journal”). I activate Alfred and type “nj <text>” and the extension automatically opens up nvALT and makes sure that there’s a note with the current date in the form “YYYY-mm-dd” and then appends my text to the end of the note with a 24 hour timestamp in front of it. It then switches back to the application that I was previously in so I can go immediately back to whatever I was doing.

Prerequisites

Download

GitHub

PyOmniFocus

A while back, I mentioned here and here that OmniFocus maintains some kind of cache of your data in a SQLite database.

I just hacked together a quick little prototype Python module for reading OmniFocus data:

https://github.com/msabramo/PyOmniFocus

Please feel free to fork it and send pull requests! Or file bugs. Or send ideas for improvements.

This could be used as part of a larger solution to pull all the data out of OmniFocus and publish it as some consumable format for the web (e.g.: XML, JSON, HTML, etc.). Or to have an OmniFocus CLI, which is what I’m most interested in.

Accessing OmniFocus data as a sqlite database

While playing with some OmniFocus AppleScripts last night, I realized that OmniFocus on the Mac uses a sqlite database (in addition to the zipped .xml files that it uses for synching). This is pretty interesting, because it could be a very convenient way to write tools that interact with OmniFocus (and use something like Python instead of AppleScript).

$ sqlite3 ~/Library/Caches/com.omnigroup.OmniFocus/OmniFocusDatabase2
SQLite version 3.7.3
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> .mode column                                                                                                                         
sqlite> .headers on
sqlite> SELECT task.name AS task, context.name AS context
   ...> FROM task JOIN context ON task.context = context.persistentIdentifier
   ...> WHERE context.name LIKE '%email%' AND task.dateCompleted IS NULL;
task                                           context   
---------------------------------------------  ----------
Send Amanda new color photo via Cloud website  Email

Pretty cool. With a little Python and SQLAlchemy, I could probably create a nice little Python module for dealing with OmniFocus data.