From 19b8b2e9957ac53f481e14b5192c37d1344a1e1b Mon Sep 17 00:00:00 2001 From: Ryan Davis Date: Sat, 11 Jan 2020 15:42:07 -0800 Subject: - Fix debug_gem task when you have a signing_key and broken rubygems (< 3.1.0). [git-p4: depot-paths = "//src/hoe/dev/": change = 12493] --- lib/hoe/debug.rb | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'lib') diff --git a/lib/hoe/debug.rb b/lib/hoe/debug.rb index 67be47b..7f36233 100644 --- a/lib/hoe/debug.rb +++ b/lib/hoe/debug.rb @@ -96,3 +96,18 @@ module Hoe::Debug end end end + +class Gem::Specification < Gem::BasicSpecification + alias old_ruby_code ruby_code + + def ruby_code(obj) + old_ruby_code obj + rescue Gem::Exception => e + case e.message + when /OpenSSL/ + "nil" + else + raise + end + end +end unless Gem::VERSION >= "3.1.0" -- cgit v1.2.1