# HG changeset patch # User Chris Cannam # Date 1432053218 -3600 # Node ID e55cbb9ba8bf96ec5b207184e9ef35881b5b9856 # Parent e2a3230f61fae577cef332918b18d04b7181f7a1 Authormap generator works, but is far too slow to run through runner diff -r e2a3230f61fa -r e55cbb9ba8bf extra/soundsoftware/get-repo-authormap.rb --- a/extra/soundsoftware/get-repo-authormap.rb Tue May 19 16:14:34 2015 +0100 +++ b/extra/soundsoftware/get-repo-authormap.rb Tue May 19 17:33:38 2015 +0100 @@ -6,13 +6,14 @@ # # ./script/rails runner -e production extra/soundsoftware/get-repo-authormap.rb soundsoftware-site -proj_ident = ARGV[1] - +proj_ident = ARGV.last proj = Project.find_by_identifier(proj_ident) repo = Repository.where(:project_id => proj.id).first csets = Changeset.where(:repository_id => repo.id) committers = csets.map do |c| c.committer end.sort.uniq committers.each do |c| - u = repo.find_committer_user c - print "#{c}=#{u.name} <#{u.mail}>\n" unless u.nil? + if not c =~ /[^<]+<.*@.*>/ then + u = repo.find_committer_user c + print "#{c}=#{u.name} <#{u.mail}>\n" unless u.nil? + end end