Class: Gem::Commands::MirrorCommand
- Inherits:
-
Gem::Command
- Object
- Gem::Command
- Gem::Commands::MirrorCommand
- Defined in:
- lib/rubygems/commands/mirror_command.rb
Instance Attribute Summary
Attributes inherited from Gem::Command
#command, #defaults, #options, #program_name, #summary
Instance Method Summary collapse
-
#description ⇒ Object
:nodoc:.
- #execute ⇒ Object
-
#initialize ⇒ MirrorCommand
constructor
A new instance of MirrorCommand.
Methods inherited from Gem::Command
add_common_option, #add_extra_args, #add_option, add_specific_extra_args, #arguments, #begins?, build_args, build_args=, #check_deprecated_options, common_options, #defaults_str, #deprecate_option, #deprecated?, extra_args, extra_args=, #get_all_gem_names, #get_all_gem_names_and_versions, #get_one_gem_name, #get_one_optional_argument, #handle_options, #handles?, #invoke, #invoke_with_build_args, #merge_options, #remove_option, #show_help, #show_lookup_failure, specific_extra_args, specific_extra_args_hash, specific_extra_args_hash=, #usage, #when_invoked
Methods included from UserInteraction
#alert, #alert_error, #alert_warning, #ask, #ask_for_password, #ask_yes_no, #choose_from_list, #say, #terminate_interaction, #verbose
Methods included from DefaultUserInteraction
ui, #ui, ui=, #ui=, use_ui, #use_ui
Methods included from Text
#clean_text, #format_text, #levenshtein_distance, #min3, #truncate_text
Constructor Details
#initialize ⇒ MirrorCommand
Returns a new instance of MirrorCommand.
6 7 8 9 10 11 12 13 |
# File 'lib/rubygems/commands/mirror_command.rb', line 6 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 |
Instance Method Details
#description ⇒ Object
:nodoc:
15 16 17 18 19 |
# File 'lib/rubygems/commands/mirror_command.rb', line 15 def description # :nodoc: <<-EOF The mirror command has been moved to the rubygems-mirror gem. EOF end |
#execute ⇒ Object
21 22 23 |
# File 'lib/rubygems/commands/mirror_command.rb', line 21 def execute alert_error "Install the rubygems-mirror gem for the mirror command" end |