lib/packaging/gem.rb in packaging-0.106.0 vs lib/packaging/gem.rb in packaging-0.106.1
- old
+ new
@@ -19,11 +19,11 @@
gem_data = JSON.parse(%x(curl --silent #{rubygems_url}))
gem = gem_data.select do |data|
data['number'] == gem_version && data['platform'] == gem_platform
end
return !gem.empty?
- rescue => e
+ rescue StandardError => e
puts "Something went wrong searching for gem '#{gem_name}':"
puts e
puts "Perhaps you're shipping '#{gem_name}' for the first time?"
return false
end
@@ -47,10 +47,10 @@
Pkg::Util::File.file_exists?("#{ENV['HOME']}/.gem/credentials", :required => true)
gem_push_command = "gem push #{file}"
gem_push_command << " --host #{options[:host]}" if options[:host]
gem_push_command << " --key #{options[:key]}" if options[:key]
Pkg::Util::Execution.capture3(gem_push_command)
- rescue => e
+ rescue StandardError => e
puts "###########################################"
puts "# Publishing to rubygems failed. Make sure your .gem/credentials"
puts "# file is set up and you are an owner of #{Pkg::Config.gem_name}"
puts "###########################################"
puts