diff options
Diffstat (limited to 'lib/rubygems/commands/search_command.rb')
-rw-r--r-- | lib/rubygems/commands/search_command.rb | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/lib/rubygems/commands/search_command.rb b/lib/rubygems/commands/search_command.rb index c9cb1f2d43..65ee25167c 100644 --- a/lib/rubygems/commands/search_command.rb +++ b/lib/rubygems/commands/search_command.rb @@ -1,15 +1,17 @@ # frozen_string_literal: true require 'rubygems/command' -require 'rubygems/commands/query_command' +require 'rubygems/query_utils' -class Gem::Commands::SearchCommand < Gem::Commands::QueryCommand +class Gem::Commands::SearchCommand < Gem::Command - def initialize - super 'search', 'Display remote gems whose name matches REGEXP' + include Gem::QueryUtils - remove_option '--name-matches' + def initialize + super 'search', 'Display remote gems whose name matches REGEXP', + :name => //, :domain => :remote, :details => false, :versions => true, + :installed => nil, :version => Gem::Requirement.default - defaults[:domain] = :remote + add_query_options end def arguments # :nodoc: |