instiki/vendor/rubyzip-0.5.6/samples/write_simple.rb
2005-01-15 20:26:54 +00:00

13 lines
No EOL
186 B
Ruby
Executable file

#!/usr/bin/env ruby
$: << ".."
require 'zip/zip'
include Zip
ZipOutputStream.open('simple.zip') {
|zos|
ze = zos.put_next_entry 'entry.txt'
zos.puts "Hello world"
}