summaryrefslogtreecommitdiff
path: root/tool/make-snapshot
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2019-04-28 00:30:16 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2019-04-28 00:30:16 +0900
commitbb6036946ef7337c8bef6380ba394c082d5452cb (patch)
treef79cb961c49efe575f92d90a0af0716caf406513 /tool/make-snapshot
parent87d2a2df1b40016401a2f6dfc98e46880bbd18fd (diff)
Reduce matz's work, let git do it instead
Diffstat (limited to 'tool/make-snapshot')
-rwxr-xr-xtool/make-snapshot15
1 files changed, 4 insertions, 11 deletions
diff --git a/tool/make-snapshot b/tool/make-snapshot
index 4e6818ac17..4ba1da522f 100755
--- a/tool/make-snapshot
+++ b/tool/make-snapshot
@@ -338,18 +338,11 @@ def package(vcs, rev, destdir, tmp = nil)
def (clean = []).add(n) push(n); n end
Dir.chdir(v) do
unless File.exist?("ChangeLog")
- # get last revision from previous ChangeLog archive
- last_ChangeLog = Dir["doc/ChangeLog-*"].grep(/-(\d+)\z/) {|n| [$1.to_i, n]}.max[1]
- open(last_ChangeLog) do |f|
- if /\Acommit (\w+)/ =~ f.readline
- beginning = $1
- elsif /\Ar(\d+) / =~ f.readline
- beginning = $1.to_i
- else
- abort "#{File.basename $0}: Cannot find revision from '#{last_ChangeLog}'"
- end
- vcs.export_changelog(url, beginning, revision, "ChangeLog")
+ # get the beginning revision from matz's commit
+ unless beginning = vcs.branch_beginning
+ abort "#{File.basename $0}: Cannot find revision from '#{last_ChangeLog}'"
end
+ vcs.export_changelog(url, beginning, revision, "ChangeLog")
end
File.open(clean.add("cross.rb"), "w") do |f|