Antonio Mat wrote:
> I have spent several hours searching for this and I still don't know how 
> it works.
> 
> How is `cmd` string encoded? I want it in UTF-8, but I don't know how to 
> do it!
> I have tried with $KCODE = 'u' but it doesn't works.
> My Ruby version is 1.8.2

Here is a solution:

  ENV["LC_ALL"] = "C.UTF-8"
  utf8_string = `cmd`

Thank you all!

-- 
Posted via http://www.ruby-forum.com/.