summaryrefslogtreecommitdiff
path: root/lib/rubygems/commands/mirror_command.rb
diff options
context:
space:
mode:
authorhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-11-10 07:20:48 +0000
committerhsbt <hsbt@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-11-10 07:20:48 +0000
commite899fb19e9a845108c264ecc0e0542d68ce97fe7 (patch)
treee6bbfb0014feefb9f2f0d5fe119b5ae8618e3777 /lib/rubygems/commands/mirror_command.rb
parenteae536ec3a41a1cade59a87db110f56456eff3ba (diff)
* lib/rubygems/*.rb: Update to RubyGems master(3e36528).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@48359 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rubygems/commands/mirror_command.rb')
-rw-r--r--lib/rubygems/commands/mirror_command.rb32
1 files changed, 17 insertions, 15 deletions
diff --git a/lib/rubygems/commands/mirror_command.rb b/lib/rubygems/commands/mirror_command.rb
index 75419c857a..24fb668d54 100644
--- a/lib/rubygems/commands/mirror_command.rb
+++ b/lib/rubygems/commands/mirror_command.rb
@@ -1,23 +1,25 @@
require 'rubygems/command'
-class Gem::Commands::MirrorCommand < Gem::Command
- def initialize
- super('mirror', 'Mirror all gem files (requires rubygems-mirror)')
- begin
- Gem::Specification.find_by_name('rubygems-mirror').activate
- rescue Gem::LoadError
- # no-op
+unless defined? Gem::Commands::MirrorCommand
+ class Gem::Commands::MirrorCommand < Gem::Command
+ def initialize
+ super('mirror', 'Mirror all gem files (requires rubygems-mirror)')
+ begin
+ Gem::Specification.find_by_name('rubygems-mirror').activate
+ rescue Gem::LoadError
+ # no-op
+ end
end
- end
- def description # :nodoc:
- <<-EOF
+ def description # :nodoc:
+ <<-EOF
The mirror command has been moved to the rubygems-mirror gem.
- EOF
- end
+ EOF
+ end
- def execute
- alert_error "Install the rubygems-mirror gem for the mirror command"
- end
+ def execute
+ alert_error "Install the rubygems-mirror gem for the mirror command"
+ end
+ end
end