mirror of
https://github.com/sinatra/sinatra
synced 2023-03-27 23:18:01 -04:00
add rake task for generating release specific contributor list
removes core team members from list, does not count backported commits (able to handle cherry-picking)
This commit is contained in:
parent
781891bf12
commit
39351ff824
1 changed files with 14 additions and 0 deletions
14
Rakefile
14
Rakefile
|
@ -66,6 +66,20 @@ task :add_template, [:name] do |t, args|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# Thanks in announcement ===============================================
|
||||||
|
|
||||||
|
team = ["Ryan Tomayko", "Blake Mizerany", "Simon Rozet", "Konstantin Haase"]
|
||||||
|
desc "list of contributors: rake thanks[1.1.0..master,1.1.0..1.1.x]"
|
||||||
|
task :thanks, [:release,:backports] do |t, a|
|
||||||
|
a.with_defaults :release => "1.1.0..master", :backports => "1.1.0..1.1.x"
|
||||||
|
included = `git log --format=format:"%aN\t%s" #{a.release}`.lines.to_a
|
||||||
|
excluded = `git log --format=format:"%aN\t%s" #{a.backports}`.lines.to_a
|
||||||
|
commits = (included - excluded).group_by { |c| c[/^[^\t]+/] }
|
||||||
|
authors = commits.keys.sort_by { |n| - commits[n].size } - team
|
||||||
|
puts authors[0..-2].join(', ') << " and " << authors.last,
|
||||||
|
"(based on commits included in #{a.release}, but not in #{a.backports})"
|
||||||
|
end
|
||||||
|
|
||||||
# PACKAGING ============================================================
|
# PACKAGING ============================================================
|
||||||
|
|
||||||
if defined?(Gem)
|
if defined?(Gem)
|
||||||
|
|
Loading…
Reference in a new issue