Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
YAML::ENGINE.yamler = 'psych'
File.open('new/en.yml', 'w') { |f| f.write(Psych.load(File.open('config/locales/en.yml').read).to_yaml) }; 1
check_with = Psych.load(File.open('new/en.yml').read)["en"].to_a; 1
Psych.load(File.open('config/locales/en.yml').read)["en"].to_a.each_with_index do |hash, i|
if check_with[i] != hash
puts hash
puts '---'
puts check_with[i]
puts '---'
break
end
end; 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.