ruby-changes:37223
From: nobu <ko1@a...>
Date: Sat, 17 Jan 2015 22:56:43 +0900 (JST)
Subject: [ruby-changes:37223] nobu:r49304 (trunk): vcs.rb: no empty names
nobu 2015-01-17 22:56:28 +0900 (Sat, 17 Jan 2015) New Revision: 49304 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=49304 Log: vcs.rb: no empty names * tool/vcs.rb (get_revisions): branch names must not be empty. Modified files: trunk/tool/vcs.rb Index: tool/vcs.rb =================================================================== --- tool/vcs.rb (revision 49303) +++ tool/vcs.rb (revision 49304) @@ -135,7 +135,7 @@ class VCS https://github.com/ruby/ruby/blob/trunk/tool/vcs.rb#L135 info_xml = IO.pread(%W"svn info --xml #{path}") _, last, _, changed, _ = info_xml.split(/revision="(\d+)"/) modified = info_xml[/<date>([^<>]*)/, 1] - branch = info_xml[%r'<relative-url>\^/(?:branches/|tags/)?([^<>]*)', 1] + branch = info_xml[%r'<relative-url>\^/(?:branches/|tags/)?([^<>]+)', 1] [last, changed, modified, branch] end @@ -209,7 +209,7 @@ class VCS https://github.com/ruby/ruby/blob/trunk/tool/vcs.rb#L209 cmd = %W[git] cmd.push("-C", srcdir) if srcdir cmd.push("symbolic-ref", "HEAD") - branch = IO.pread(cmd)[%r'\A(?:refs/heads/)?(.*)', 1] + branch = IO.pread(cmd)[%r'\A(?:refs/heads/)?(.+)', 1] [last, changed, modified, branch] end -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/