Easy way that compress files in ruby is using ziphttps://www.rubydoc.info/github/rubyzip/rubyzip/Zip/File lib.
Zip::File.open'./compress.zip', create: true do |zip|
zip.getoutputstream"./stufftoziped.pdf" do |f|
f.puts File.read"./stufftozip.p...
If you want to understand how things work beyond what's under the hood, the first good step is to try to write something from scratch. So, in this post, I will show you how to write a 'hello world' app for the web in pure Ruby. Above, you'll find the...