Skip to content
master
Switch branches/tags
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 

README.md

The Cdo plugin is now deprecated. Vim 8 adds almost identical native :cdo and :ldo commands, with additional functionality.


Cdo

Example: Find every instance of foo in the working directory and replace it with bar.

:grep foo
:Cdo s/foo/bar/c | update

Commands

:Cdo [command]

    Runs the same command over every entry in the quickfix list.

:Ldo [command]

    Runs the same command over every entry in the location list.

:Cdo/c [command]

    Just like |:Cdo|, but asks for confirmation before changing each file.

:Ldo/c [command]

    Just like |:Ldo|, but asks for confirmation before changing each file.

Setup

In order for :Cdo to function, you must add the following line to your .vimrc file:

set hidden

Set hidden allows the buffers to stay open while :Cdo makes changes to each file in the list.

Credits

Cdo was written by Peter Jaros (@peeja), with contributions from Danielle Sucher (@DanielleSucher).

About

Vim commands to run a command over every entry in the quickfix list (:Cdo) or location list (:Ldo).

Resources

Releases

No releases published

Packages

No packages published