1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Fix glob base in bundler.gemspec

This commit is contained in:
Kazuhiro NISHIYAMA 2019-11-18 23:41:26 +09:00 committed by Kazuhiro NISHIYAMA
parent 9aa75795f9
commit fea24bbfdb
Notes: git 2019-11-19 00:29:32 +09:00

View file

@ -159,7 +159,8 @@ module Spec
def with_root_gemspec
if ruby_core?
root_gemspec = root.join("bundler.gemspec")
spec = Gem::Specification.load(gemspec.to_s)
# Dir.chdir(root) for Dir.glob in gemspec
spec = Dir.chdir(root) { Gem::Specification.load(gemspec.to_s) }
spec.bindir = "libexec"
File.open(root_gemspec.to_s, "w") {|f| f.write spec.to_ruby }
yield(root_gemspec)