ruby-changes:65890
From: Hiroshi <ko1@a...>
Date: Mon, 19 Apr 2021 18:19:38 +0900 (JST)
Subject: [ruby-changes:65890] 93420d34aa (master): Added the specific files to the default gems like net-http and optparse
https://git.ruby-lang.org/ruby.git/commit/?id=93420d34aa From 93420d34aaf8c30f11a66dd08eb186da922c831d Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA <hsbt@r...> Date: Mon, 19 Apr 2021 18:19:09 +0900 Subject: Added the specific files to the default gems like net-http and optparse --- tool/rbinstall.rb | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/tool/rbinstall.rb b/tool/rbinstall.rb index abeae88..141b670 100755 --- a/tool/rbinstall.rb +++ b/tool/rbinstall.rb @@ -710,13 +710,22 @@ module RbInstall https://github.com/ruby/ruby/blob/trunk/tool/rbinstall.rb#L710 end end - if base - Dir.glob("#{base}{.rb,/**/*.rb}").collect do |ruby_source| - remove_prefix(prefix, ruby_source) - end - else - [File.basename(@gemspec, '.gemspec') + '.rb'] + files = if base + Dir.glob("#{base}{.rb,/**/*.rb}").collect do |ruby_source| + remove_prefix(prefix, ruby_source) + end + else + [File.basename(@gemspec, '.gemspec') + '.rb'] + end + + case Pathname.new(@gemspec).basename(".gemspec").to_s + when "net-http" + files << "lib/net/https.rb" + when "optparse" + files << "lib/optionparser.rb" end + + files end def built_libraries -- cgit v1.1 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/