1

Ruby has default source encoding to ASCII, to alter the source encoding, it is necessary to use magic encoding comments on the header of each file will help the Ruby interpreter to load file in that encoding.

I've done my homework, I know there is three encoding in Ruby and the external or internal encoding which could be set by switches)

To config Ruby with default source encoding (such as utf-8) without any touch on my program files, I could use Ruby -e to launch my files.

How to enable this in a Rails environment such in unicorn or rails wrapepr?

steveyang
  • 9,178
  • 8
  • 54
  • 80

0 Answers0