summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2019-08-26 18:21:04 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2019-08-26 18:27:17 +0900
commit48f1a38f23f9a544e71c5656c83c419c064509fd (patch)
treeb529860fc928c8d201397529fd169073c9d159f0
parent972222c039bc5f5aa4a0d5bd6ec48ff4629e0fff (diff)
Limit ChangeLog entries
Since the previous release date, when the starting message is not found.
-rw-r--r--tool/lib/vcs.rb11
1 files changed, 8 insertions, 3 deletions
diff --git a/tool/lib/vcs.rb b/tool/lib/vcs.rb
index 15ec4c16db..db0af885da 100644
--- a/tool/lib/vcs.rb
+++ b/tool/lib/vcs.rb
@@ -572,9 +572,14 @@ class VCS
unless $?.success?
raise "need notes/commits tree; run `git fetch origin refs/notes/commits:refs/notes/commits` in the repository"
end
- range = [from, (to || 'HEAD')].compact.join('^..')
- cmd_pipe({'TZ' => 'JST-9', 'LANG' => 'C', 'LC_ALL' => 'C'},
- %W"#{COMMAND} log --format=medium --notes=commits --date=iso-local --topo-order #{range}", "rb") do |r|
+ cmd = %W"#{COMMAND} log --format=medium --notes=commits --date=iso-local --topo-order"
+ to ||= 'HEAD'
+ if from
+ cmd.push("#{from}^..#{to}")
+ else
+ cmd.push("--since=25 Dec 00:00:00", to)
+ end
+ cmd_pipe({'TZ' => 'JST-9', 'LANG' => 'C', 'LC_ALL' => 'C'}, cmd, "rb") do |r|
format_changelog(r, path)
end
end