[Rubygems-developers] Tracking RubyGems as a dependency

James Tucker jftucker at gmail.com
Wed Jul 7 14:11:15 EDT 2010

On 7 Jul 2010, at 17:17, Jeremy Hinegardner wrote:

> On Wed, Jul 07, 2010 at 04:36:43PM +0100, James Tucker wrote:
>> Hi again,
>> One of the things that has come up along the lines of research for better
>> integration with system package managers is the idea of tracking rubygems
>> itself as a dependency for gem code. Some package managers simply strip out
>> "require 'rubygems'" from 3rd party code, which in most cases is workable
>> given their installation plan, however, some libraries may use the Gem API,
>> for example Gem.gunzip or the like (for want of a better example). I recognise
>> it's hard to get 3rd party users to fill in gemspecs fully, and I have other
>> ideas for that, but in light of simply allowing dependency lists to be filled
>> in correctly, should there be a method to do this in the gemspec?
>> At present specs contain a rubygems_version field that I'm not sure we even
>> use. Can we add some kind of "uses_rubygems" boolean field for this purpose,
>> as it seems depending on rubygems-update would be quite incorrect.
> I do believe this is the purpose of the :required_rubygems_version field
> in the gemspec.
>  ##
>  # :attr_accessor: required_rubygems_version
>  #
>  # The RubyGems version required by this gem
>  attribute :required_rubygems_version, Gem::Requirement.default

That claims therefore that *every* gem requires rubygems, which the folks I'm talking about will tell you isn't true. I'm trying to help them automate their tools by way of using spec fields that are valid. If this field was defaulted to nil, then explicitly set, then it would be valid.

> enjoy,
> -jeremy
> -- 
> ========================================================================
> Jeremy Hinegardner                              jeremy at hinegardner.org 
> _______________________________________________
> Rubygems-developers mailing list
> http://rubyforge.org/projects/rubygems
> Rubygems-developers at rubyforge.org
> http://rubyforge.org/mailman/listinfo/rubygems-developers

More information about the Rubygems-developers mailing list