diff --git a/ChangeLog b/ChangeLog index 3cda6e3ce7..b701124c98 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Thu Dec 26 10:27:53 2013 NAKAMURA Usaku + + * tool/merger.rb (tag): support 2.1.1 semi-automatic tagging and 2.2.0 explicit tagging. + Thu Dec 26 06:35:25 2013 Marc-Andre Lafortune * proc.c: Having any mandatory keyword argument increases min arity diff --git a/tool/merger.rb b/tool/merger.rb index 82f43aac6e..819f980601 100755 --- a/tool/merger.rb +++ b/tool/merger.rb @@ -25,11 +25,14 @@ backport from other branch revision increment ruby #$0 revisionup -tagging patch release +tagging major release + ruby #$0 tag 2.2.0 + +tagging patch release (about 2.1.0 or later, it means X.Y.Z (Z > 0) release) ruby #$0 tag tagging preview/RC - ruby #$0 tag 2.0.0-preview1 + ruby #$0 tag 2.2.0-preview1 * all operations shall be applied to the working directory. end @@ -107,27 +110,34 @@ end def tag intv_p = false, relname=nil # relname: - # * 2.0.0-preview1 - # * 2.0.0-rc1 - # * 2.0.0-p0 - # * 2.0.0-p100 + # * 2.2.0-preview1 + # * 2.2.0-rc1 + # * 2.2.0 v, pl = version x = v.join('_') if relname - abort "patch level is not -1 but '#{pl}' even if this is new release" if pl != '-1' + abort "patchlevel is not -1 but '#{pl}' for preview or rc" if pl != '-1' && /-(?:preview|rc)/ =~ relname + abort "patchlevel is not 0 but '#{pl}' for the first release" if pl != '0' && /-(?:preview|rc)/ !~ relname pl = relname[/-(.*)\z/, 1] - curver = v.join('.') + '-' + pl + curver = v.join('.') + (pl ? '-' + pl : '') if relname != curver - abort "geiven relname '#{relname}' conflicts current version '#{curver}'" + abort "given relname '#{relname}' conflicts current version '#{curver}'" end branch_url = `svn info`[/URL: (.*)/, 1] else if pl == '-1' abort "no relname is given and not in a release branch even if this is patch release" end - branch_url = $repos + 'branches/ruby_' + x + branch_url = $repos + 'branches/ruby_' + if v[0] < "2" || (v[0] == "2" && v[1] < "1") + abort "patchlevel must be greater than 0 for patch release" if pl == "0" + branch_url << x + else + abort "teeny must be greater than 0 for patch release" if v[2] == "0" + branch_url << x.sub(/_\d+$/, '') + end end - tagname = 'v' + x + '_' + pl + tagname = 'v' + x + (v[0] < "2" || (v[0] == "2" && v[1] < "1") || /^(?:preview|rc)/ =~ pl ? '_' + pl : '') tag_url = $repos + 'tags/' + tagname if intv_p interactive "OK? svn cp -m \"add tag #{tagname}\" #{branch_url} #{tag_url}" do