aboutsummaryrefslogtreecommitdiffstats
path: root/tool/enc-unicode.rb
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-03-23 15:55:00 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-03-23 15:55:00 +0000
commit765946b82ba73808155bead607959f471a955e6a (patch)
tree3d4a5b95ed253f6df2af81a22de60783abe0258d /tool/enc-unicode.rb
parent7f0c39519dfc2d23fd7385bfdfc25fe4c94fb308 (diff)
downloadruby-765946b82ba73808155bead607959f471a955e6a.tar.gz
enc-unicode.rb: fix version matching
* tool/enc-unicode.rb (data_foreach): version comments do not include sub directory names. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58070 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'tool/enc-unicode.rb')
-rwxr-xr-xtool/enc-unicode.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/tool/enc-unicode.rb b/tool/enc-unicode.rb
index 220c46c8ef..baa05da496 100755
--- a/tool/enc-unicode.rb
+++ b/tool/enc-unicode.rb
@@ -307,7 +307,7 @@ end
def data_foreach(name, &block)
fn = get_file(name)
warn "Reading #{name}"
- pat = /^# #{name.sub(/\./, '-([\\d.]+)\\.')}/
+ pat = /^# #{File.basename(name).sub(/\./, '-([\\d.]+)\\.')}/
File.open(fn, 'rb') do |f|
line = f.gets
unless pat =~ line