From: Austin Ziegler Date: 2006-07-01T04:52:04+09:00 Subject: Re: [RubyGems] Rational about the Gem package format? On 6/30/06, Jacob Fugal wrote: > On 6/30/06, transfire@gmail.com wrote: > > I was just wondering about the rational behind the format of gem > > packages. It seems rather odd that the package is a tar of > > > > data.tar.gz > > metadata.gz > > > > Why not just have the metadata stored in with the data and not worry > > about double layers? The only advantage I can figure is that it is > > possilble to extract the metadata without uncompressing the eniter > > package. Okay, but can't a tar/gzip lib or tool do that anyway? Is > > there some other reason? > I think it's for the reason you mentioned. tar can extract specific > files out of the package without needing to extract the whole package, > but -- if I recall correctly -- the gzip compression format still > requires that the whole package be decompressed before the files could > be extracted. So compressing the metadata and actual data separately > means you only need to decompress the metadata if that's all you're > after. It's also the format of .deb files, more or less. (Debian files actually have control.tar.gz and data.tar.gz.) -austin -- Austin Ziegler * halostatue@gmail.com * http://www.halostatue.ca/ * austin@halostatue.ca * http://www.halostatue.ca/feed/ * austin@zieglers.ca