RubyFlow The Ruby and Rails community linklog

×

The Ruby and Rails community linklog

Made a library? Written a blog post? Found a useful tutorial? Share it with the Ruby community here or just enjoy what everyone else has found!

Mixing code and data in Ruby with DATA and __END__

Did you know that Ruby provides a way for your script to use its own source file as a source of data? It’s a neat trick that can save you some time when writing one-off scripts and proofs of concept. Let’s check it out! http://blog.honeybadger.io/data-and-end-in-ruby/

Post a comment

You can use basic HTML markup (e.g. <a>) or Markdown.

As you are not logged in, you will be
directed via GitHub to signup or sign in