How to never forget to enable your time tracking timer. | Dafacto

The personal website of Matt Henderson.

How to never forget to enable your time tracking timer.

08 March 2012

Over the years, I’ve used several Mac app to track my time while working — On the Job, TrackRecord, Billings,… you name it. The main problem I’ve had with all of them is remembering to enable the timer as I work. Sometimes I’d end the day, only to realize I hadn’t tracked any of my time.

Recently, we’ve started using the online service Harvest, which comes with its own desktop app for the Mac. It’s fine, but like the others, doesn’t solve the problem I have in remembering to start the timer.

Finally, with the help of Makalu’s system administrator shell scripting wizard Niall, I have a solution.

For a long time, I’ve been a heavy user of Keyboard Maestro — an app that lets non-programming pointy-haired bosses like me, create scripts to automate their Macs. Ugly website, but a great product. Here’s some cool things I do with Keyboard Maestro:

  • With the tap of a keystroke, I create a new contact record in Daylite, each time we get a new RaceSplitter customer.
  • Each morning, my online backup tool, Arq, gets its upload bandwidth throttled (while I work), and then gets opened up again during the night.
  • With the tap of a keystroke, create a temporary document in Notational Velocity, containing the contents of the clipboard.
  • With the tap of a keystroke, open all my project-related folders and URLs.
  • With the tap of a keystroke, shoot myself a quick email with the contents of the clipboard.

And now, with Keyboard Maestro, I’ve solved the problem of remembering to turn on my timer.

Harvest provides an API that developers can use to interact programatically with the service. One of the actions available to Keyboard Maestro scripts is to run a shell script, and act on the results.

I combined the two to create a script that runs every 5 minutes beteween 8:30 AM and 7:30 PM, sending a request to the Harvest API, and checking the response to see if a timer is active. If a timer is not active, I growl an alert to myself and switch into the Harvest app.

So far, this solution has worked great for me!

If you’re interested, here’s a visual of the script:

Enjoy this article? — You can find similar content via the category and tag links below.

Questions or comments? — Feel free to email me using the contact form below, or reach out on Twitter.