Manage #TODO (lots of files) with VIM

Question:

I use VIM/GVIM to develop my python projects and I randomly I leave #TODO comments in my code.

Is there any way to manage (search, list and link) all the #TODO occurrences inside VIM? I tried the tasklist plugin, it’s almost what I need, but it only lists the current file #TODO occurrences. Generally my projects has some sub-folders and many .py files, so I’d like to find a way to search through all folders and files in the current working directory and list them.

Asked By: Magnun Leno

||

Answers:

If you just want a list of the occurences of “TODO” in .py files in the working directory, you can just use :vimgrep like so:

:vimgrep TODO **/*.py

Then open the quickfix window with:

:cw

(it might open it automatically anyway, not sure) and just scroll through the results, hitting Enter to go to each occurrence.

For more complicated management, I’d probably recommend setting up an issue tracker.

Answered By: Liquid_Fire
Categories: questions Tags: , , ,
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.