Created
June 26, 2011 21:49
-
-
Save chrismdp/1048010 to your computer and use it in GitHub Desktop.
Committer stats
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
committers = `git log --pretty=format:%an` | |
authors = [] | |
committers.each_line do |commit| | |
commit.chomp.split(' and ').map{|a| authors.push a} | |
end | |
stats = Hash.new(0) | |
authors.map do |author| | |
stats[author] += 1 | |
end | |
stats.sort{|a,b| b[1]<=>a[1]}.each { |elem| | |
puts "#{elem[0]} (#{elem[1]})" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment