Logo
Explore Help
Sign In
1berry/ruby
1
0
Fork 0
You've already forked ruby
Code Issues Packages Projects Releases Wiki Activity
ruby/gem_prelude.rb

7 lines
116 B
Ruby
Raw Normal View History

Do not call 'gem "did_you_mean"' for now This will slow down the time that the +require+ method takes to load DYM, but this has caused a build failure in a certain situation: https://ci.appveyor.com/project/ruby/ruby/builds/29214253/job/r9u9c8p95tnlftt3#L24965 which is reported as a separate bug: https://bugs.ruby-lang.org/issues/16382?next_issue_id=16381 For now this commit should fix the builds, but we should come back and add back the 'gem' call.
2019-11-29 21:40:07 -05:00
require 'rubygems.rb' if defined?(Gem)
Don't fail when 'did_you_mean' is not available. Although 'did_you_mean' is always available in upstream Ruby, it might not be available when speed, memory, disk or network bandwidth is a concern. This is typically the case for production environment, where 'did_you_mean' is of limited usage. Also it might not be available optionally when Ruby is delivered via packaging systems. E.g. Linux distributions.
2019-12-18 14:29:17 +01:00
begin
require 'did_you_mean'
rescue LoadError
end if defined?(DidYouMean)
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.23.8 Page: 263ms Template: 2ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API