Using Org Mode with GTD

Both Org Mode and Planner Mode are really neat ways to maintain a schedule, and almost sufficient reason to use Emacs in and of themselves. I’ve tried them both, and have found that Org Mode integrates easier with the way that I prefer to work.

Make sure you see the Org Tutorial and the excellent GTD with Org Mode site. What follows are just some quick notes for a particular configuration that worked for me.

First of all, be sure to set up your .emacs as recommended in the aforementioned Org tutorial:

(add-to-list 'load-path "~/emacs/org")
(require 'org)
(add-to-list 'auto-mode-alist '("\\.org$" . org-mode))
(define-key global-map "\C-cl" 'org-store-link)
(define-key global-map "\C-ca" 'org-agenda)
(setq org-log-done t)

I prefer to have my personal and work stuff in separate files, with a master file that points to all of them. This makes it easier for me to concentrate on only work when I’m at work, so…

(setq org-agenda-files 
      (list "~/org/gtd.org" "~/org/work.org" "~/org/personal.org"))
Each .org file has the following header:
#+TAGS: WORK (or whatever)
#+TYP_TODO: TODO MAYBE WAITING NEXT DONE
#+STARTUP: showall
#+STARTUP: hidestars
Finally, some configuration tweaks that work for me:
; I prefer return to activate a link
(setq org-return-follows-link t)
 
(setq org-agenda-custom-commands 
    '(("w" todo "WAITING" nil) 
    ("n" todo "NEXT" nil)
    ("d" "Agenda + Next Actions" ((agenda) (todo "NEXT"))))
)
 
(defun gtd ()
   (interactive)
   (find-file "~/org/gtd.org")
)

Daily

Now, to see the day’s agenda, you can do C-c a for an overall agenda. While at work, I have the work.org file in a buffer window; to see what I’m working on, I go to the work.org file and do a C-c a 1 followed by C-a d. This a) narrows the task list to those in work.org, and b) shows me all scheduled tasks and all tasks that are marked as “NEXT.”

Weekly

At the end of every week I go through the different files and use the Org Mode archive stuff. Sometimes I move it into an archive file, sometimes I don’t; it kind of depends how many other things are going on with that particular project.

Miscellaneous

I keep all my organization stuff on a USB drive, and for convenience also have links to encrypted files that I might need to refer to from time to time. I keep bcrypt on the USB drive, and added the following Elisp hack:

(defun open-encrypted-file (fname)
  (interactive "FFind file: \n")  
  (let ((buf (create-file-buffer fname)))
    (shell-command 
     (concat "echo " (read-passwd "Decrypt password: ") " | bcrypt -o " fname)
     buf)
    (set-buffer buf)
    (kill-line)(kill-line)
    (toggle-read-only)
    (not-modified))
  )
And, with an Elisp link in my gtd.org, I can easily see my passwords:
[[elisp:(open-encrypted-file "~/org/passwords.txt.bfe")][Passwords]]