On Wed, Mar 22, 2017 at 02:51:23PM -0400, leam hall wrote:
> How do I take Ruby code and package it so I can give it to a Winderz or mac
> user and they can run it without having to install Ruby? I would assume the
> binaries would be different, but doable.

For Windows, there's OCRA[1]. It basically sticks a complete MRI Ruby
interpeter into a self-extracting ZIP file along with your script. When
the user executes the resulting .exe file, it first decompresses the
entire Ruby interpreter and then uses that to run the script. As you can
imagine, the startup time is rather slow therefore.

On recent Mac systems, Ruby is preinstalled to my knowledge, so you
don't have that problem at all.

In my opinion, if you can't tell the user to install a Ruby interpreter,
you shouldn't use Ruby for creating programs for that user. Ruby is no
one-size-fits-all language.

Marvin

[1]: https://github.com/larsch/ocra/

-- 
Blog: https://www.guelkerdev.de
PGP/GPG ID: F1D8799FBCC8BC4F

Unsubscribe: <mailto:ruby-talk-request / ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-talk>