From: Daniel Berger Date: 2007-01-12T04:40:07+09:00 Subject: Re: Tattle - The Ruby Census Sammy Larbi wrote: > Daniel Berger wrote, On 1/11/2007 12:35 PM: > > How about: > > > > spec = Gem::Specification.new do |gem| > > gem.add_dependency("something", ">= 1.2.0") > > gem.add_optional("rspec", "Test suite only", ">= 0.5.0") > > ... > > end > > > > And, at the command prompt: > > > > C:\gem install something > > > > Install required dependency something? [Yn] > > Install optional dependency rspec (Test suite only) [Yn] > > > > The problem I see with that is similar to removing programs in Windows. > Often, it says something to the effect of "it appears no programs are > using the xxxxxx.dll file. Do you want to remove that too?" Well, how > would I know? I don't know what it does. I think any optional > dependencies would need a good description of what it is and why you > would want it. Something better than a small phrase, anyway. Ok, so we do the same thing for uninstalls: C:\gem uninstall rspec something-0.1.0 has an optional dependency on [rspec (>= 0.5.0)] (Test suite only) Continue with Uninstall? [Yn] We could also include the optional dependency's description at this point. Regards, Dan