From: "Stephan Kämper" Date: 2005-02-18T03:24:52+09:00 Subject: Re: Need to create zip files James Britt wrote: > Thomas Sondergaard wrote: > >> "DaZoner" wrote in message >> news:... >> >>> RubyZip's docs do not have a "hey! this is how you use this to make a >>> zip" explanation and the methods aren't really documented - just >>> source code is shown. Anyone have examples or other docs? > > file_name: The (base) name of a to-be-zipped file FILES_DIR: The directory where the file lives PACKED_DIR: The directory where the zip file is created Zip::ZipFile.open( "#{ PACKED_DIR }/#{ file_name }.zip", Zip::ZipFile::CREATE ) { | zip | zip.add( "#{ file_name }.rb" , "#{ FILES_DIR }#{ file_name }.rb" ) } Beware of the line breaks. HTH Happy rubying Stephan