Skip to content

Instantly share code, notes, and snippets.

@wilkerlucio
Created August 13, 2013 17:38
Show Gist options
  • Save wilkerlucio/6223640 to your computer and use it in GitHub Desktop.
Save wilkerlucio/6223640 to your computer and use it in GitHub Desktop.
" Ag replace
function! ProjectAgReplace(search)
silent execute "args `ag -l " . a:search . "`"
let repcmd = "%s/" . a:search . "/"
let replace = input(repcmd)
execute "argdo" repcmd . replace
endfunction
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment