Skip to content

Instantly share code, notes, and snippets.

@petergi
Created December 14, 2025 05:40
Show Gist options
  • Select an option

  • Save petergi/e21aa36e897aa38e89a20fca618182df to your computer and use it in GitHub Desktop.

Select an option

Save petergi/e21aa36e897aa38e89a20fca618182df to your computer and use it in GitHub Desktop.
Search through Git branches for particular text. In this case I am looking at reference to Anthropic or Claude.
# Search in files across all branches
git grep -i "claude\|anthropic\|generated with.*claude\|co-authored-by.*claude" $(git rev-list --all) -- ':(exclude)go.sum' ':(exclude)go.mod' | head -50
# Search in commit messages
git log --all --grep="Claude\|Generated with\|Co-Authored" --oneline
# Search for specific patterns in current branch
grep -r "Claude Code\|Co-Authored-By: Claude\|🤖 Generated" . --exclude-dir=.git --exclude-dir=build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment