Time Tracking with Drafts

I’ve started sharing how I track my time with drafts on my micro.blog:


Once I’ve finished the series, I’ll have links to the actions involved.


Here’s the final post in the series, with links to download the actions I use.

If you have any questions, just ask!



Hi Ciaran, thanks for sharing your workflow with Drafts. I found your approach very interesting. I have installed your action group today, and it seems that it is not working well for me. The “process timeslip” action doesn’t result in useful outputs in the email content. Please find attached some screenshots with the issue, and let me know if you have any suggestions.
Thanks again four your great work.

The problem is that you did not enter different client numbers for each client. The script has combined all the time together because all the entries are associated with the same (blank) client number. If you edit the clientList.json file to include different client numbers (or if you just delete that file entirely and add unique numbers when prompted)the script will work as expected.

1 Like

(let me know if that doesn’t fix things—I do really want this to work for people!)

1 Like

You are right. That fixed the issue. The requirement of the client number might be a good addition to the action description, or the summary in your blog.
I will try this in the next days and I will let you know how it goes.

Good suggestion. Please also note that you need to use “0” as the client number for items you want the script to ignore, like “lunch” in the example above.

I’ll add a blog post clarifying these things.

I’ve updated the action group so that, even if you don’t enter unique client numbers, you’ll still get correct results. The revised script matches clients based on the standardized client name, rather than the client number.

Please note, however, than if you want the script to ignore certain entries (like “lunch”) you’ll need to add a “client” with 0 as the client number and aliases that include whatever you don’t want to track (e.g. lunch,break, etc.)

1 Like

Quick note of gratitude to you for creating this action group. I’ve long been interested in using plain text for time tracking.

I’m slowly adapting the actions to suit my workflow. No straightforward task for me as I’m not a programmer and know little about scripting. That said, your scripts are proving to be a fun and motivating environment for me learn within.

Writing this response to make sure you know your efforts are very useful and appreciated.


Hey thank you!

Glad to hear that the scripts are useful to you. As always, if you have questions or encounter issues with the scripts, let me know!

Hi Ciaran,

thanks for sharing. Very interesting to see what‘s possible with plain text.

When running „process timeslip“ multiple times on the same slip, the data gets added multiple times to the time.txt file.

I‘m no JavaScript programmer. Any chance you could add some check to prevent multiple processing?

Edit: Sorry, I didn‘t recognized that a tag „processed“ is already added to the slip. Now I just need to filter for that tag.

Hi Steinthal,

You’re right. If you run “process timeslip” on the same timeslip multiple times, it will add the data from the timeslip to the .txt file multiple times.

The intention, of course, is that you only process each timeslip once. Personally, my default “after success” setting is to have the Draft be deleted. But if yours is different, you could change the Process Timeslip action to archive or delete the drafter after success to achieve the same effect.

If you really need to add a “processed” tag, you would need to add another script step to the Process Timeslip action, at the very end, that includes something like this: