After a summer of working on various ways to implement it, I’m happy to
announce that I’m putting the first release of my Ruby Summer of Code
project, ruby_archive 0.1.0, out into the wild.
It’s available on rubygems as well as at
ruby_archive lets you use files within zip files much like normal files
your filesystem. This means you can package data files and Ruby
within convenient zip files and still use them easily from your program.
For open, load, require, and most File.*** and Dir.*** operations, you
access files within archives by targetting at a location like the
It also allows you to package your entire program in one file and run it
using the included ‘rba_launch’ program.
See the readme file at the github site or in the rdoc for full
It works on ruby-1.8.7, jruby, rubinius, and ruby-head, and probably
interpreters and versions. Let me know if and when you run into any
problems, I will be continuing work on this project beyond the Ruby
of Code deadline.
A goal of the project was to put this type of functionality up for
consideration to be included in the Ruby interpreter - feedback related
this is welcome as well.