Skip to content

Instantly share code, notes, and snippets.

@juliantcook
Created January 19, 2023 10:54
Show Gist options
  • Select an option

  • Save juliantcook/bd1b6f9d292baeb8b7fb2f464c41b931 to your computer and use it in GitHub Desktop.

Select an option

Save juliantcook/bd1b6f9d292baeb8b7fb2f464c41b931 to your computer and use it in GitHub Desktop.
Revert all commits matching a grep.
git log --grep "${1}" --no-merges --oneline | cut -d ' ' -f1 | xargs git revert --no-edit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment