<div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif">The ruby <<- heredoc syntax, unlike the << heredoc syntax, will strip indentation if necessary. Technically, it searches for the "least indented line" in the whole string, and removes exactly that amount from each line. So yes, the indentation problem -is- solved in ruby (though it might break entirely if you have empty lines, since the least indented line has no indentation).</div><div class="gmail_default" style="font-family:verdana,sans-serif"><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Dec 11, 2015 at 12:36 AM, Paul Cantrell <span dir="ltr"><<a href="mailto:cantrell@pobox.com" target="_blank">cantrell@pobox.com</a>></span> wrote:<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><div>In Ruby in the wild, off the top of my head and totally unscientifically, the most widely-used flavors I’ve seen are the heredoc with interpolation and terminator indentation:</div><div><br></div><div><div> string = <<-EOS</div><div> gone is music</div><div> yet you sing</div><div> EOS</div></div></div></blockquote><div> </div></div>
</div></div>