Maintenance Ruby 3.3 gets fixes, but no new features. Switch to Ruby 4.0 →
instance method
Gem::Command#handles?
handles?(args)
lib/rubygems/command.rb
View on GitHub ↗
# File tmp/rubies/ruby-3.3.0/lib/rubygems/command.rb, line 429
def handles?(args)
parser.parse!(args.dup)
true
rescue StandardError
false
end
True if the command handles the given argument list.
See also
#handle_options
#invoke
#get_one_optional_argument
#invoke_with_build_args
also in
4.1 · 4.0 · 3.4 · 3.2 · 3.1 · 3.0