Ruby 2.1.0 YAML regression
# Double quote
require 'YAML'
yaml1 = {"key" => %Q{<%= ENV["PATH"] %>} }.to_yaml
puts yaml1
# Single quote
require 'YAML'
yaml2 = {"key" => %Q{<%= ENV['PATH'] %>} }.to_yaml
puts yaml2
Double Quote (note the slash before the quote)
---
key: "<%= ENV[\"PATH\"] %>"
and single quote
---
key: "<%= ENV['PATH'] %>"
Double Quote (note no slash)
---
key: <%= ENV["PATH"] %>
Single Quote
---
key: <%= ENV['PATH'] %>