Created
December 9, 2022 22:26
-
-
Save anvit/faa84d7beb9990c7ab20ed10be0ee9aa to your computer and use it in GitHub Desktop.
Generate diffs for every author in a git repo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
read -p "Enter repo url: " url | |
git clone $url && cd "$(basename "$_" .git)" | |
mkdir -p ../diffs | |
git log --format='%aN' | sort -u | xargs -I % sh -c 'git log --author "%" -p > "../diffs/%.diff"' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment