tenderlove/psych — Issue #49: Is it a YAML Document?
Author: trans
Created: 2012-02-29 13:04:58+00:00
State: open

Is there any way to detect if a file and/or string is YAML?

Maybe something like:

YAML.document?(io_or_text)

would be a good addition, if not.