"You build atomic bombs, you wage wars, you murder, cheat, and lie to us and try to make us believe it's for our own good, yet we're the criminals. Yes, I am a criminal. My crime is that of curiosity. My crime is that of judging people by what they say and think, not what they look like." - Hacker's manifesto _

.:: TODO buffer in Emacs ::.

I wanted to have a buffer when pressing F4 that recursively lists all TODO and FIXME comments in a directory together with the filenames. Here is a simple solution for that:

(defun balle-grep-todos-in-dir (dir &optional not-recursive)
"Grep recursively for TODO comments in the given directory"
(interactive "Ddirectory:")
(let ((recur "-r"))
(if not-recursive
(setq recur "")
(grep (concat "grep -nH -I " recur " -E \"[\\#\\/\\-\\;\\*]\s*TODO|FIXME|XXX:?\" " dir " 2>/dev/null"))
(enlarge-window 7)
(global-set-key [f4] 'balle-grep-todos-in-dir)

posted at 21:54:20 on 06/27/11 by balle - Category: Emacs

.:: Comments ::.

Mens Danny Trevathan Jersey wrote:

Hurrah! In the end I got a website from where
I know how to truly take helpful facts concerning my study and knowledge.
12/14/14 05:51:04

Add Comments