From: Roger Pack Date: 2010-11-03T01:51:23+09:00 Subject: [ruby-core:33011] Re: not use system for default encoding >> Yeah, if you don't want dynamic decision with locale >> you can specify File.read("foo.txt", encoding:"UTF-8"). > > Yeah I'm just afraid that newbies won't realize this, because it is > implicit (hidden) on their local machines. My latest thought is that files' default encoding can (should?) be binary. Then there's no confusion, and if they want to read it with an encoding, they can specify so. For console input, it makes sense to have a default encoding, but not really for files. At least from my perspective :) I also noted that a few others agree that having a "system dependent" file default encoding seems bad form [1]. Cheers! -r [1] http://github.com/candlerb/string19/blob/master/soapbox.rb#L75 (the whole thing is a good read :)