You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Anyway to access information about the source of YAML when defining a type? I have a case where I want to know if the source was a file and what the file path is.
YAML::add_domain_type("foo.com,2011", "foo") do |type, value|
from_file = ? # 'foo.yaml'
Foo.new(value, :file=>from_file)
end
YAML.load(File.new('foo.yaml'))
The text was updated successfully, but these errors were encountered:
Anyway to access information about the source of YAML when defining a type? I have a case where I want to know if the source was a file and what the file path is.
The text was updated successfully, but these errors were encountered: