ZLIB::GzipWriter - Strange file encoding?

Hey Folks,

I have this code:

Zlib::GzipWriter.open(“file.gz”) do |gz|
gz.write(File.read(“file.csv”))
end

Unfortunately this file doesn’t want to open correctly in UltimateZip.
It shows a file inside, but doesn’t allow you to extract it.

Am I missing something here? Seems pretty cut and dry…


Brian C.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs