Skip to content

Monthly Archives: April 2017

Search All Git Branches for Specific Text/Regex

11-Apr-17

git branch -a | tr -d \* | sed '/->/d' | xargs git grep [string or regex] This can be slow, though, and git log may be more effective. git log -p --all -S 'search string' git log -p --all -G 'match regular expression' This produces list of commits, so we need to find branches […]