Skip to content

Instantly share code, notes, and snippets.

@tomask-de
Created April 25, 2018 07:30
Show Gist options
  • Select an option

  • Save tomask-de/5916b64a298b55328ac672fd8573b20d to your computer and use it in GitHub Desktop.

Select an option

Save tomask-de/5916b64a298b55328ac672fd8573b20d to your computer and use it in GitHub Desktop.
find and replace oneliner
for f in `find . -name "*.go" | xargs grep -l "<OLD>"`; do sed -i -e 's/<OLD>/<NEW>/g' $f; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment