You probably want vimgrep for this particular use case. For example, opening vim in your source directory and entering :vimgrep /^#TODO/i *.txt *.md
will populate the quickfix list with all the lines in text and markdown files which begin with #TODO. You can then use :cnext
and :cprev
to jump around the files.
Look at :help vimgrep
and :help :filename
for more information on vimgrep and the {file}
argument respectively. You can expand the regex to match more tags (e.g. note) or use :w
in your quickfix window to save the file.