Class: Gem::Commands::PushCommand
- Inherits:
-
Gem::Command
- Object
- Gem::Command
- Gem::Commands::PushCommand
- Defined in:
- lib/rubygems/commands/fake_push_command.rb
Overview
Because of the way Gem commands are loaded, it isn’t possible at this time to override the #send_gem method without resorting to monkey patching.
Instance Method Summary collapse
Instance Method Details
#execute ⇒ Object
6 7 8 9 10 11 12 13 14 15 |
# File 'lib/rubygems/commands/fake_push_command.rb', line 6 def execute name = get_one_gem_name gem_name, version = File.basename(name).scan(/(.*)-([\d\.]+).gem/).first sleep 0.5 puts 'Pushing gem to RubyGems.org...' sleep 2 puts "Successfully registered gem: #{gem_name} (#{version})" end |