title: Ruby - UTF-8 file encoding
body: <p>We all know the "magical"</p>
  
  <pre><code># encoding: utf-8
  </code></pre>
  
  <p>line. But I've seen several other alternative notations, some of them pretty wild. Do you know or use any of those? Is there some more general rule of what is acceptable?</p>
  
  <p>Edit: Ok, apparently there are exactly 3 ways:</p>
  
  <pre><code># encoding: UTF-8
  
  # coding: UTF-8
  
  # -*- coding: UTF-8 -*-
  </code></pre>
  
  <p>(more at <a href="http://blog.grayproductions.net/articles/ruby_19s_three_default_encodings" rel="noreferrer">http://blog.grayproductions.net/articles/ruby_19s_three_default_encodings</a>)</p>