wiki:SchemaProposalYGNI

Version 3 (modified by anonymous, 9 years ago) (diff)

--

YGNI - YAML's Gonna Need It

A YAML Schema Language Proposal by Ingy

An Example Schema

This is just some stream of conciousness stuff. Not done yet...

---
top:
  path: //
  tag:  '!<tag:ingy.net,2004:person>
  kind: map
  keys:
    - key: name
      value: '!!str'
      required: y
    - key: age
      value: '!!int'
      required: y
    - key: nationality
      value: '!nationality'


nationality:
  type: enum
  values: [black, white, yellow, red, green]