On Wednesday, 19 December 2012 00:37:23 UTC-5, Ruby-Forum.com User
wrote:
Expected output:
en:
01: “red, green”
It’s certainly possible, but if you want the output YAML to look like
that
you’re going to need to put the input data into the same sort of
format.
For instance, running the expected output (with quotes around 01, to
avoid
it being parsed as an integer) through YAML.load gives this Ruby result:
{“en”=>{“01”=>“red, green”}}
–Matt J.
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.