Skip to content

Instantly share code, notes, and snippets.

@jhuttner
Last active August 29, 2015 13:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jhuttner/8795868 to your computer and use it in GitHub Desktop.
Save jhuttner/8795868 to your computer and use it in GitHub Desktop.
git-who-owns-what
#!/bin/bash
# git-who-owns-what
#
# Requires: git-remote-authors: https://gist.github.com/jhuttner/8795653
#
# Print the branches that each user was the last committer for.
#
# Place this script in your PATH, chmod +x it, and git will allow you to magically do:
# $ git who-owns-what
#
# Author: devops@appnexus.com
# Last modified: 3 February 2014
#!/bin/bash
names=\
"First1 Last1
First2 Last2
First3 Last3"
while read i; do echo --- $i; git remote-authors 1 | grep -B1 "$i" | grep Branch; done < <(echo -e "$names")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment