From 8289771e326006cc4e15a667e3eff3a72cfb3327 Mon Sep 17 00:00:00 2001 From: drbrain Date: Thu, 20 Dec 2007 08:39:12 +0000 Subject: Import RubyGems 1.0.0, r1575 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14361 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/rubygems/commands/query_command.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'lib/rubygems/commands/query_command.rb') diff --git a/lib/rubygems/commands/query_command.rb b/lib/rubygems/commands/query_command.rb index 581d4bb734..4f957625ee 100644 --- a/lib/rubygems/commands/query_command.rb +++ b/lib/rubygems/commands/query_command.rb @@ -82,8 +82,10 @@ class Gem::Commands::QueryCommand < Gem::Command end entry = gem_name.dup + if options[:versions] then - entry << " (#{list_of_matching.map{|gem| gem.version.to_s}.join(", ")})" + versions = list_of_matching.map { |s| s.version }.uniq + entry << " (#{versions.join ', '})" end entry << "\n" << format_text(list_of_matching[0].summary, 68, 4) if -- cgit v1.2.3