Bugs item #27698, was opened at 2010-01-18 11:31 You can respond by visiting: http://rubyforge.org/tracker/?func=detail&atid=575&aid=27698&group_id=126
Category: `gem` commands (other) Group: v1.3.x Status: Open Resolution: None Priority: 3 Submitted By: J Smith (darkpanda) Assigned to: Nobody (None) Summary: Inconsistent handling of Strings versus Symbols in gemrc Initial Comment: It seems that the gem command can't make up its mind whether it should be using Symbols or Strings in the gemrc configuration file. As an example, given the following gemrc: --- sources: - http://gems.rubyforge.org/ - http://gems.github.com/ :gem: --no-ri --no-rdoc Look at how the following commands execute: [u...@testbox ~]% sudo gem install activerecord Password: Successfully installed activerecord-2.3.5 1 gem installed Installing ri documentation for activerecord-2.3.5... Installing RDoc documentation for activerecord-2.3.5... [u...@testbox ~]% gem sources *** CURRENT SOURCES *** http://gems.rubyforge.org/ The install command is ignoring the arguments that were set using :gem and proceeded to install ri and rdoc documentation and the sources command ignored the github repository. Now, take that same gemrc but switch up the 'sources' String for a Symbol and the :gem Symbol for a String: --- :sources: - http://gems.rubyforge.org/ - http://gems.github.com/ gem: --no-ri --no-rdoc And issue the same commands to gem: [u...@testbox ~]% sudo gem install activerecord Successfully installed activerecord-2.3.5 1 gem installed [u...@testbox ~]% gem sources *** CURRENT SOURCES *** http://gems.rubyforge.org/ http://gems.github.com/ Now the arguments set on 'gem' in the configuration file work and the so does the github repository added via :sources. This is very wtf -- is the gemrc configuration file supposed to be using Strings as keys, Symbols as keys, both or neither? Here's my environment output: RubyGems Environment: - RUBYGEMS VERSION: 1.3.5 - RUBY VERSION: 1.8.6 (2009-03-31 patchlevel 368) [i686-darwin10.0.0] - INSTALLATION DIRECTORY: /opt/local/lib/ruby/gems/1.8 - RUBY EXECUTABLE: /opt/local/bin/ruby - EXECUTABLE DIRECTORY: /opt/local/bin - RUBYGEMS PLATFORMS: - ruby - x86-darwin-10 - GEM PATHS: - /opt/local/lib/ruby/gems/1.8 - /Users/test/.gem/ruby/1.8 - GEM CONFIGURATION: - "gem" => "--no-ri --no-rdoc" - :sources => ["http://gems.rubyforge.org/", "http://gems.github.com/"] - REMOTE SOURCES: - http://gems.rubyforge.org/ - http://gems.github.com/ ---------------------------------------------------------------------- You can respond by visiting: http://rubyforge.org/tracker/?func=detail&atid=575&aid=27698&group_id=126 _______________________________________________ Rubygems-developers mailing list http://rubyforge.org/projects/rubygems Rubygems-developers@rubyforge.org http://rubyforge.org/mailman/listinfo/rubygems-developers