Refined installation of gemspecs placed other than ext and lib
This commit is contained in:
parent
813fe4c256
commit
31f4dec637
@ -701,14 +701,15 @@ module RbInstall
|
|||||||
when "lib"
|
when "lib"
|
||||||
base = @base_dir
|
base = @base_dir
|
||||||
prefix = base.sub(/lib\/.*?\z/, "") + "lib/"
|
prefix = base.sub(/lib\/.*?\z/, "") + "lib/"
|
||||||
|
else
|
||||||
|
# other/something.gemspec ->
|
||||||
|
# [other/something.rb, other/something/foo.rb, ...]
|
||||||
|
base = @gemspec.chomp('.gemspec')
|
||||||
|
prefix = @base_dir
|
||||||
end
|
end
|
||||||
|
|
||||||
if base
|
Dir.glob("#{base}{.rb,/**/*.rb}").collect do |ruby_source|
|
||||||
Dir.glob("#{base}{.rb,/**/*.rb}").collect do |ruby_source|
|
remove_prefix(prefix, ruby_source)
|
||||||
remove_prefix(prefix, ruby_source)
|
|
||||||
end
|
|
||||||
else
|
|
||||||
[File.basename(@gemspec, '.gemspec') + '.rb']
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user