There are two 'types' to be aware of with a quickfix window:
- entry: the actual line content (e.g.
:grep foo
will show a specific line that matched within a file). - file: the actual file itself (e.g. the path to the file that contained the match).
To replace content using vim (via the quickfix window) you need to choose whether you want to apply the change via the quickfix 'entry' or via the 'file' as a whole.
If you use cdo
, then your 'action' (i.e. how you're going to replace content) will be applied to every entry in the quickfix window.
If you use cfdo
, then your action will be applied to each file in the quickfix window.