Skip to content

aofdev/yaml-peg

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

yaml-peg

Check lint, format and tests

PEG parser (pest) for YAML written in Rust 🦀

Quick Start ⚡️

# Run
cargo run -- --file example_files/test.yaml

# Output
{
  "xmas": "true",
  "calling-birds": "[\"huey\", \"dewey\", \"louie\", \"fred\"]",
  "birds": "[\"huey-2\", \"dewey-2\"]",
  "french-hens": "3",
  "ray": "a drop of golden sun",
  "test1": "false",
  "doe": "a deer, a female deer",
  "pi": "3.14159",
  "array-test": "[\"DFASf\", \"2222\"]",
  "str-folded-style": "  that is folded  into two lines  and it is not indented  into three lines\n",
  "str-literal-style": "  this is my very very very\n  long string\n  that is folded\n  into two lines\n  and it is not indented\n"
}

TODO

  • One level
  • String multiline (folded-style, literal-style)
  • Nested levels
  • YAML 1.2
  • Change binary to library