[Rubygems-developers] Testing for Gems 0.9.0 Beta

Jim Weirich jim at weirichhouse.org
Wed Mar 29 09:46:37 EST 2006

Tom Copeland wrote:
>> I wanted to run some ideas by you.  One of the big changes 
>> scheduled for 
>> RubyGems 0.9.0 is how the gem command downloads the gem index from 
>> RubyForge.  Currently, gem grabs the entire wad of gem specs if it 
>> detects that the size of the index file has changed.  The new version 
>> will incrementally download only those gems that have been 
>> updated since 
>> the last download.  Hopefully this will cut down download bandwidth a 
>> bit and speed up the end user experience.
> Hi Jim -
> Sounds great!  Yup, I've talked with Rich about this a bit.

Tom, here is the software to generate the rubygems server index files. 
The script is index_gem_repository.rb and is called as follows:

    index_gem_repository.rb -d REPO_DIRECTORY

Where REPO_DIRECTORY is where the yaml file is currently placed.  In 
addition to the standard yaml/yaml.Z files produced, it will also 
produce a quick directory containing each gem spec individually zipped 
and ready for incremental downloads.

If you want to see output while the script runs, just include a 
--verbose option.  There's a --help option too.

Although this will be part of the gem 0.9.0 release, I've tested it with 
version 0.8.0 and it will work fine, so you don't have to upgrade your 
entire gem setup on the machine to try this out.

I've tested this quite a bit on my personal gem repository and am 
confident it won't break existing gem downloads, it probably a good a 
idea keep the old indexing software around (just in case :).

Once you start running this on RubyForge, I will put together a beta 
release of gems for limited distribution for testing the incremental 


-- Jim Weirich       jweirich at one.net      http://onestepback.org
"Beware of bugs in the above code; I have only proved it correct,
not tried it." -- Donald Knuth (in a memo to Peter van Emde Boas)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: index_gem_repository.rb
Type: application/x-ruby
Size: 7268 bytes
Desc: not available
Url : http://rubyforge.org/pipermail/rubygems-developers/attachments/20060329/0b35f20d/attachment-0001.bin 

More information about the Rubygems-developers mailing list