Feature #3465
closedimprove gem_prelude's Quickloader's Gem.bin_path
Description
=begin
The situation currently with rubygems' generated scripts is that they contain a line like
gem 'gem_name', '>= 0' # gem_prelude handles this well
load Gem.bin_path('gem_name', 'binary_name', '>= 0') # gem_prelude is forced to load full rubygems with this line, which takes quite awhile and is frequently unnecessary.
Suggestion:
Supplement gem_prelude's QuickLoader with an ability to look for the default bin path, and, if it's there, return it, without loading full rubygems.
With the attached file included in gem_prelude, on my local windows box, loading of a ruby script goes from
3.8s to 0.65s
On Linux it causes script execution (for a gem binary command) to go from 0.5s to 0.13s
The attached patch file "should" fit straight into gem_prelude.rb in trunk. I can provide a true diff if desired.
Thanks much.
-rp
=end
Files
Updated by rogerdpack (Roger Pack) almost 14 years ago
=begin
Sorry that was meant to be a feature request, not bug.
Thanks.
-r
=end
Updated by rogerdpack (Roger Pack) almost 14 years ago
=begin
Here's an updated patch, seems to work well.
=end
Updated by rogerdpack (Roger Pack) over 13 years ago
- Status changed from Open to Rejected
=begin
moving this feature request to rubygems proper and/or the faster_rubygems gem.
=end