diff options
Diffstat (limited to 'lib/yaml.rb')
| -rw-r--r-- | lib/yaml.rb | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/lib/yaml.rb b/lib/yaml.rb index e47e0a7f9b..c6f0f89fd2 100644 --- a/lib/yaml.rb +++ b/lib/yaml.rb @@ -3,9 +3,17 @@ begin require 'psych' rescue LoadError - warn "It seems your ruby installation is missing psych (for YAML output).\n" \ - "To eliminate this warning, please install libyaml and reinstall your ruby.\n", - uplevel: 1 + case RUBY_ENGINE + when 'jruby' + warn "The Psych YAML extension failed to load.\n" \ + "Check your env for conflicting versions of SnakeYAML\n" \ + "See https://github.com/jruby/jruby/wiki/FAQs#why-does-the-psych-yaml-extension-fail-to-load-in-my-environment", + uplevel: 1 + else + warn "It seems your ruby installation is missing psych (for YAML output).\n" \ + "To eliminate this warning, please install libyaml and reinstall your ruby.\n", + uplevel: 1 + end raise end @@ -40,7 +48,7 @@ YAML = Psych # :nodoc: # # == History # -# Syck was the original for YAML implementation in Ruby's standard library +# Syck was the original YAML implementation in Ruby's standard library # developed by why the lucky stiff. # # You can still use Syck, if you prefer, for parsing and emitting YAML, but you @@ -54,8 +62,10 @@ YAML = Psych # :nodoc: # For more advanced details on the implementation see Psych, and also check out # http://yaml.org for spec details and other helpful information. # -# Psych is maintained by Aaron Patterson on github: https://github.com/tenderlove/psych +# Psych is maintained by Aaron Patterson on github: https://github.com/ruby/psych # -# Syck can also be found on github: https://github.com/tenderlove/syck +# Syck can also be found on github: https://github.com/ruby/syck module YAML + # The version of YAML wrapper + LOADER_VERSION = "0.4.0" end |
