escape( value, skip = "" )
Escape the string, condensing common escapes
# File lib/yaml/encoding.rb, line 10 def YAML.escape( value, skip = "" ) value.gsub( /\\/, "\\\\\\" ). gsub( /"/, "\\\"" ). gsub( /([\x00-\x1f])/ ) do skip[$&] || ESCAPES[ $&.unpack("C")[0] ] end end