{% extends "base.html" %} {% block meta_title %}Is it YAML?{% endblock %} {% block main %}
The file you entered is properly formatted and has been presented in 'canonical' form for your perusal.
{{ yamlcanon }}{% endif %} {% if yamlstate == 2 %}
I'm afraid the text you entered is not legitimate YAML. Here's an error message.
{{ yamlerror }}
Here's the original text, just so you can check where things went wrong.
{{ yamloriginal }}{% endif %} {% if yamlstate != 0 %}
Enter some text in the text field below and click "Submit" to check if it is YAML. Hit "Reset" to reset the whole contents.
"Is it YAML?" is a Django application for checking whether text is YAML ("a human friendly data serialization standard for all programming languages"), or not. Users type and/or copy and paste text and clicks the "Submit" button above. If valid YAML has been entered, the input is presented in canonical form. Invalid input causes the application to present an error message.
YAML is just a text format for exchanging data. It exists for cases where XML is too much overhead. I like YAML. I find it more robust in practice than XML (where one missing angle bracket could corrupt a whole file), yet easier to type by hand.
I conjured up "Is it YAML?" while writing a specification for YPath - a language for addressing parts of a YAML document, as XPath does for XML. To do a proper job of things, I had to write YAML example files. However, I sometimes needed to check if the example files are good and proper. "Is it YAML?" gave me a test bed where I can copy-and-paste my examples, and see if they really are YAML.
Apart from Django, the app depends on PyYAML, a Python parser for YAML. You can get the application from PyPI through the command:
pip install isityaml
Once installed, just add "isityaml" to your INSTALLED_APPS list in settings.py, and add the desired URL in one of the urls.py files.
The installation comes with a HTML template file designed to work with Mezzanine, a Django CMS. You are looking at the result. Feel free to customise: the app is released under a 3 clause BSD license.
Copyright © Peter Murphy 2011, 2012, 2013, 2014.
{% endblock %}