INCLUDE_DATA

Keeping track of my to do list with plain text

To keep track of all my different projects, things I should be doing and anything else that I’m apt to forget I use a to do list. In the beginning my list usage was heavily inspired by David Allen’s Getting Things Done philosophy. The GTD principles worked, but it was a lot of hassle for what I consider the simple task of organizing and using a to do list. After some time I ended up with a simplified version of GTD – I keep a list of all the stuff I should remember, or things I plan to do, and I look at the list a couple of times per day to ensure I don’t forget anything important. It is a very simple system, but so far it is working for me.

One thing I spent a lot of time on in the start phase of my list usage was how to organize the list. There are a lot of different online list management system available, as well as multiple off line programs to manage to do lists. I’m a bit skeptical about using an online service for my list tracking since I prefer to keep have complete control over my personal data. As I’m getting dependent on the list it would be really annoying if the online service decided to go down for maintenance for a day or two. So I was going to use an off line program for organizing my to do list. Keeping the list on my laptop would also ensure that I always had the list with me, since I usually keep my laptop close at hand. If I only had my stationary computer I would probably have gone with an online solution, but luckily I didn’t have to do that.

Among the various to do list programs the one that caught my interest at once was Todo.txt. It is a very simple system based on plain text files and command line usage. The fact that it is created for command line usage is for me a big bonus for me, since that gives me the option of piping the output through various programs like sort and awk to generate reports in whatever format I desire. When I’m sitting in front of my computer I always have at least one terminal open, so a command line interface give me easy access to it as well. Todo.txt stores the to do list as plain text files in your home directory (or wherever you configure it to store stuff) so it is very easy to keep backups of the lists compared to other programs that have special storage formats which require backup of both the program and the data files.

Installation of Todo.txt is very easy. First step is to download the Todo.txt file bundle from the Google Code repository. Once it is downloaded you move the file to your home directory and extract it.

cp <path to download directory>/todotxt-bundle-1.0.zip ~/.
cd ~
unzip todotxt-bundle-1.0.zip

That will place a bunch of files at various places in your home directory, as well as create the folders needed for Todo.txt to function. The documentation is also part of the file package and after extraction it is available at ~/doc/*.

To make Todo.txt even easier to use I’ve aliased t to the todo.py program. This can be done my adding the following line to your .bashrc file.

alias t='todo.py'

Now I can access the to do list by simply typing t in the terminal. Things doesn’t get much easier than that! The shortcut will be loaded automatically when a terminal session is started. To get the shortcut to work in your current terminal session you can type source ~/.bashrc.

Now that Todo.txt has been installed and the shortcut has been created it is ready for use. The basic usage of adding items to the list, printing the list and then removing items are done with the following commands

$ t add test todo.txt
Added: test todo.txt
$ t ls
   1: test todo.txt
$ t do 1
Done 1: test todo.txt

The first command adds whatever is behind t add to the list. Items added to the list doesn’t require any specific syntax, but to get the most out of Todo.txt there are a couple of conventions that should be followed. To associate a list item with a project you add the project name using p:<project-name>. You can also associate list items with various contexts, e.g internet and phone. So to add an item to my blog project that should be done while online I would type

t add write about important stuff p:blog @internet

Using these conventions to create project and context associations for the items makes it easy to later on extract the relevant items. Todo.txt also has a report feature which can display the status of various projects in your to do list when you use the syntax described above.

List items can also be given priorities, which are displayed as colored output when you view the list. Adding a high priority item to the list is done by typing

t add (A) this is very important

The priority is set by the (A). Placement of the (A) is irrelevant, but to make everything easier to read I prefer to place them at the beginning of the list item. To give it an item lower priority you can change the letter with a “higher” letter (e.g (B) or (C)).

Listing the items in your to do list is done with the second command above, t ls. If you only want to see a subset of your to do list you can append search criteria which will narrow down the list. To find all items associated with my blog project I could use:

t ls p:blog

You can also search for specific words, since the search criteria is applied using straight forward string matching. It is a very simple way of filtering the list, but it provides enough power to give you the information you require – especially when you use special naming conventions for projects and contexts.

There is another way to get a list of all the items, the Bird’s Eye View. This will display all of the items on the list ordered by project and context, as well as give some statistics about how the various projects are progressing. You can get bird’s eye report by executing

t birdseye

To mark an item as done you first have to get the internal id of the list item. That number is displayed when you output the list items.

$ t ls
   1: test todo.txt
   2: write more stuff

Above you see a to do list with two items. The number in front is the list item’s internal id, this is the number that is required to mark an item as done. To mark the “write more stuff“-item as done I use

t do 2

This tells Todo.txt that the item with id 2 is done. When I now list the items in the list the “write more stuff“-item is omitted.

$ t ls
   1: test todo.txt

Those commands covers the basic usage of Todo.txt. There are a couple of other commands available, with descriptions supplied by t help, but since I don’t use them that often I’ll skip those for now. When I accustomed to the remaining commands I might write about their usage as well.

Leave a Comment